Recently, in the project, I encountered a relatively special requirement, for example, in MySQL, such as December 13, 2004, Week 1, if you want to get 0:00 on Mondi 0:00 (that is, 2004 How do you write about 0:00 on December 6th, December 12, 2004? In fact, you can write this way, after my exploration and discovery, know: For example, your date field is col1
WHERE week (color_days (curdate ()) - 7) The week starts since the week, 0 is expressed as starting from Sunday. And from_days (to_days (curdate ()) - 7 is returned last week (7 days ago), use Week (from_days (to_days (curdate ()) - 7)), you can seek last week 1 To Sunday, all the eligible dates between all meetings. Of course, it can be expanded before, returning the date between any time period