I have managed to do a work around but was wondering if there is an actual method..
Icon::whereNotIn( 'id', Icon::has( 'keywords' )->lists( 'id' ) )->paginate( 40 );
The second parameter to has() is $operator and the third is $count. So:
Model::has('relation', '=', 0);
Sign in to participate in this thread!
The Laravel portal for problem solving, knowledge sharing and community building.
The community