mardi 24 mai 2016

Eloquent: Query the length of field in Laravel

I want to do something like that in Laravel (valid sqlite query):

select * from 'tbUsers' where  length(name)>50;

I tried

User::with('Permissons')->where('LENGTH(name)','>','50')->get();

But it seems not to work...

note: other queries works without problem:

User::with('Permissons')->where('active,'=','1')->get();



from Newest questions tagged laravel-5 - Stack Overflow http://ift.tt/1TJiiCx
via IFTTT

Aucun commentaire:

Enregistrer un commentaire