I have the following query that I am trying to get to work properly. I want to show all the records of the previous week.
select * From my_table Where week(Date_Entered,3)=week(SUBDATE(now(),Interval 7 day),3)
What it is doing is showing only those records of the previous week that are after 7 days from now.
eg this week is week 49
last week is week 48
now is 04/12/02
It will only show records with week 48 after and including the 27/11/02 (7 days previous)
I hope this is clear????
Thanks in advance for any help received.
select * From my_table Where week(Date_Entered,3)=week(SUBDATE(now(),Interval 7 day),3)
What it is doing is showing only those records of the previous week that are after 7 days from now.
eg this week is week 49
last week is week 48
now is 04/12/02
It will only show records with week 48 after and including the 27/11/02 (7 days previous)
I hope this is clear????
Thanks in advance for any help received.