select * from sccp_raw
where dt between curdate() - interval 11 day
and curdate() - interval 4 day
limit 5;
mysql print data between dates
Question
Hi I have below mysql table
mysql> select * from test_raw limit 5;
dt admin balance
2013-08-02 AR 8734736
2013-08-02 AZ 190
2013-08-02 BA 7007
2013-08-02 BE 7125
2013-08-02 BG 5189
I want to print data of a week considering that week starts from Thursday to Wednesday and I want to run query on Monday. Please suggest a way to print this data, is there a way to give date range between now( ) -11 to -4 day ?
Solution
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow