MySQL如何按照日期字段查询?
表Table1中有 日期字段TestDate,现在想按照天查询。
但是MySQL不支持TestDate=?。该如何写呢?
select * from Table1 where testdate .......?
谢谢大家!
[解决办法]
select * from Table1 where testdate=date_format(‘2011-09-15','%Y-%M-%d')
是这个意思吗
[解决办法]
发布时间: 2012-09-18 16:21:42 作者: rapoo
MySQL如何按照日期字段查询?
表Table1中有 日期字段TestDate,现在想按照天查询。
但是MySQL不支持TestDate=?。该如何写呢?
select * from Table1 where testdate .......?
谢谢大家!
[解决办法]
select * from Table1 where testdate=date_format(‘2011-09-15','%Y-%M-%d')
是这个意思吗
[解决办法]