condition for both of one should be true laravel eloquent

Solutions on MaxInterview for condition for both of one should be true laravel eloquent by the best coders in the world

showing results for - "condition for both of one should be true laravel eloquent"
Isabell
02 Apr 2019
1WHERE age < 6 OR (age > 8 AND name IN ('Jane', 'Jerry'))
2  
3return \App\Dogs::select('name', 'age')
4    ->where('age','<', 6)
5    ->orWhere(function($q){
6        $q->where('age','>', 8);
7        $q->whereIn('name', ['Jane', 'Jerry']);
8    })
9    ->get();
similar questions