Support the ongoing development of Laravel.io →

4,311 Threads

Search where results only if value is not empty

Hello Guys , I have a filter search , and I want to search WHERE , JUST if the value is not empty ....

0 Likes
3 Replies

\App\Model::all() not grabbing more than 15 entries

Hi all, Wanting to grab an entire model to dump in CSV format for a report, however, in this case, u...

0 Likes
0 Replies

How to update database table when change the Migration ?

If I change the Migration Structure (such like CreatePasswordResetsTable) How I to change the databa...

0 Likes
5 Replies
Solved

Join count group

Lets say I have the following code. $ideas=IdeaUser::join('ideas as idea', 'idea.fk_user_id', '...

0 Likes
5 Replies

laravel select count(b.id) left join group by, table name not format

When I use the code below, error occurs . DB::table('area as a') ->select('a.*', DB::...

0 Likes
0 Replies

How to prevent Model::findOrFail sent header

In a RestFul API, I want to handle the exception before sent header. How could I do that?

0 Likes
0 Replies

Self model relation

Hi to all. Since I designed my db, I came out with a self related model in my entity relational diag...

0 Likes
0 Replies

Case-sensitive eager loading and string based foreign key issue

I've a one DataBase(game) where some tables has own prefix and own relations which not related with...

0 Likes
3 Replies

Problem with non integer foreign keys hasOne/hasMany Relationship

Currently I have a problem with a relation, defined by a non integer foreign key. I know, foreign ke...

0 Likes
1 Replies

OrderBy related model?

We have posts and theyneed to be sorted by Authors name and Category popularity. I have tried smth l...

0 Likes
0 Replies

BadMethodCallException in Macroable.php line 74: Method specialization does not exist

I am getting this small issue. Below is the source code Doctor Model: class Doctor extends Model {...

0 Likes
0 Replies
posted 7 years ago

Tinker and model mutators

I have a model that encrypts and decrypts values using mutators, as described here: https://laravel....

0 Likes
0 Replies

Eloquent create says column has no default value

In Laravel 5.1 I've setup my models and added the $fillable array like I usually would. My User mod...

0 Likes
15 Replies

QueryException SQLSTATE[42S22]: Column not found: 1054 Unknown column 'id' in 'where clause'

Illuminate \ Database \ QueryException SQLSTATE[42S22]: Column not found: 1054 Unknown column 'id' i...

0 Likes
2 Replies
Solved
posted 7 years ago

Laravel — Loop all data from multiple tables

good day. I have researched about it, but nothings matched with my problem. Here's the scenario. I h...

0 Likes
1 Replies

Laravel 5.4 Images from database not showing in view.

Hey guys, In my application I have some images that belong to some articles. These are shown perfect...

0 Likes
1 Replies

Laravel one to one relational data access.

I have users table and profiles table. One to one relation. I have one view to show both user and pr...

0 Likes
0 Replies

Comparing Two tables using laravel query builders using a column as reference

i want to get the result of code below in laravel query builder or better still eloquent Adding the...

0 Likes
0 Replies

Best practice to test a return from an eloquent request

Hi, I have this request : $sale = Sale::where('alias', '=', $alias)->first(); What is the best pr...

0 Likes
6 Replies

Error with Queue Job and Laravel-Mongo DB

Hi ! I use this package and queue of Laravel 5.4. When I dispatch a job, I have an error : Next Ill...

0 Likes
0 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.

© 2024 Laravel.io - All rights reserved.