mysql:查询今天、一周内、一月内数据
程序员文章站
2022-05-24 14:36:15
...
SELECT * FROM `nation`
where to_days(create_time) = to_days(now())
SELECT * FROM `nation`
where DATE_SUB(CURDATE(), INTERVAL 7 DAY) <= date(create_time)
SELECT * FROM `nation`
where DATE_SUB(CURDATE(), INTERVAL 30 DAY) <= date(create_time)
上一篇: javaweb自动登录(cookie)
下一篇: Ribbon负载均衡调用