标签:hda div mys color 查询 code bsp rom curd
一、查询当前时间包含年月日
SELECT CURDATE();
SELECT CURRENT_DATE();
二、查询当前时间包含年月日时分秒
SELECT NOW();
SELECT SYSDATE();
三、查询当天数据
SELECT t1.* FROM user1 t1 WHERE TO_DAYS(t1.`birthday`) = TO_DAYS(NOW()); SELECT * FROM user1 t1 WHERE t1.`birthday` BETWEEN DATE_FORMAT(NOW(), ‘%Y-%m-%d 00:00:00‘) AND NOW(); SELECT * FROM user1 t1 WHERE DATE(t1.`birthday`) = CURDATE();
标签:hda div mys color 查询 code bsp rom curd
原文地址:https://www.cnblogs.com/lcl-cn/p/14458219.html