I want to get all previous records from my mysql table from selected month and year. e.g if my selected month and year is 08-2018 then query should show all the previous records from Aug 2018.
I have tried this mysql query as :
"select * form tblusers where year(created_date)<=2018 and month(created_date)<'08'";
but it did not include record from when I have month greater than 8 e.g 09-2017 etc