MySQL 时间
SELECT count(1) from cw_capture_count WHERE date = DATE_SUB(CURDATE(),INTERVAL 1 DAY); //查询当前时间往前推一天
SELECT count(1) from cw_capture_count WHERE date = DATE_SUB(CURDATE(),INTERVAL 0 DAY); //查询当前日期
SELECT count(1) from cw_capture_count WHERE date = DATE_SUB(CURDATE(),INTERVAL -1 DAY); //查询当前时间往后推一天
SELECT count(1) from cw_capture_count WHERE date = DATE_SUB(CURDATE(),INTERVAL -1 MONTH); //查询当前时间往后推一月
SELECT count(1) from cw_capture_count WHERE date = DATE_SUB(CURDATE(),INTERVAL -1 YEAR); //查询当前时间往后推一年
java基础知识