Here is my code using mysql command
SELECT * FROM `order_list` WHERE currentdate like '%12%' and currentdate like '%2017%'
but Im having a problem converting it into laravel eloquent.
$orderlists = Orderlist::where('currentdate', 'like', "%$month%")
->where('currentdate', 'like', "%$year%")
->get();
is this correct?thanks
LIKE. mysql hasYEAR()orMONTH()function which fit better.currentdate like '%12%'you search what? 12 as a day, or 12 as a month (december).