Support the ongoing development of →
Database Eloquent IOC
Last updated 1 year ago.

Ok guys, i just found out what was missing, a subquery in the county whereHas, pretty noobie error that i found in the queryLog. This may serve for someone in the future.

Paginator::setPageName('page_pools'); $pools = Team::where('team_type','=','pool') ->whereHas('users',function ($q) { $q->whereHas('roles', function ($q){ $q->where('name','NOT LIKE', '%Admin%'); }); }) ->whereHas('county', function($q) use ($filter){ ( $q->where(function($q2) use ($filter) { $q2->where('name','LIKE','%'.$filter.'%')->where('abrev','LIKE','%'.$filter.'%','OR'); }));}) ->paginate(9);

Last updated 1 year ago.

Sign in to participate in this thread!


Your banner here too?

thiduzz thiduzz Joined 23 Sep 2014


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

Your logo here?

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

© 2023 - All rights reserved.