MYSQL取出30天前的数据 关键就在于DATEDIFFA(time1,time2)这个函数,它能计算出time2-time1之间相隔的天数: select * from log where DATEDIFF(now(),time) >=30; Please enable JavaScript to view the comments powered by Disqus. Post Directory