Support the ongoing development of Laravel.io →

4,604 Threads

Laravel Eloquent Saving by batch

is there any way on how to save a Whole batch of file using eloquent ? For example I have a 1000 ite...

0 Likes
1 Replies

Customer count by day for the last 30

Hi Everyone! I am working on building out charts and a little confused on the best approach. I am lo...

0 Likes
0 Replies

Eloquent Query pivot data

Hi, I am having problem with my query. I have 4 tables users,prospects,leads,items. All of them rela...

0 Likes
0 Replies
posted 7 years ago

In query, Laravel shows error, but query works

I have an interesting conundrum where creating a query in Laravel is giving me an error, but if I co...

0 Likes
1 Replies

Define a relationship as a union

Hi, I would like to know if there is a way to define a relationship as a union of two tables? I've a...

0 Likes
1 Replies

Laravel 5.4 Database Placement Questions

I know how I can get the data needed, but want to follow Laravel/MVC practices here and new to it. I...

0 Likes
1 Replies

what should contain in pivot table

I'm trying to use pivot table. But I'm confused how should I define my database tables. Concept: Pac...

0 Likes
1 Replies
Solved

[L 5.4] how to forbid multiple responses

Hey guys! In my applicatio, every logged in user can open a "feedback-site". That site has...

0 Likes
1 Replies

Updating a model doesn't work when specifying a morphMany relationship in the withCounts attribute

Has anyone ever run into an issue where you can create records just fine, but the moment you want to...

0 Likes
0 Replies

Structure Suggestions

I'm having difficulty conceptualizing a good way to organize my models, so I'm hoping that maybe som...

0 Likes
0 Replies

Parse error: syntax error, unexpected end of file

I'm just working with laravel, And I use the model to store data,When I register, I encounter the fo...

0 Likes
0 Replies

opposite eloquent method to grabbing related data

I am looking for the opposite of getting all Data that is related in a many to many relations, thus...

0 Likes
5 Replies
Solved

Laravel Eloquent using 'with' and 'where'

Laravel 5.4 I am having a hard time using "with" and "where" together. Instead o...

0 Likes
0 Replies

save() function doesn't work and does not output an error

Hello, I am experiencing a strange problem with the built-in User class in Laravel. Its save() funct...

0 Likes
10 Replies
Solved
posted 7 years ago

Table Ripper

Hello community, I apologize if this is not the place for this, but I wanted to present a package I...

0 Likes
1 Replies

Display multiple json objects present in the single data cell

I have a column say placeditems where each time an user places his order a json object is stored.So,...

0 Likes
0 Replies

Facing problem in outputting a query's result

I have a query whose result is single column and outputs array(1) { [0]=> object(stdClass)#243 (1...

0 Likes
0 Replies

Laravel Adding Bulk data in Polymorphic Relationship

Suppose we have this schema: Set id name Question questionable_type questionable_id...

0 Likes
0 Replies

FatalErrorException syntax error, unexpected 'public' (T_PUBLIC) in Product.php (line 14)

<?php namespace App\Http\Controllers; use Illuminate\Http\Request; use App\Slide; use App\Produ...

0 Likes
0 Replies

Should I have to reload a relationship after an attach()?

I have some code that looks like this: class User { public function addRoleById($role_id) {...

0 Likes
4 Replies

Thanks to our community

Solutions given in the past year. Excluding solutions from thread authors.

Moderators

We'd like to thank these amazing companies for supporting us

Your logo here?

Laravel.io

The Laravel portal for problem solving, knowledge sharing and community building.

© 2025 Laravel.io - All rights reserved.