非常简单的查询如下:
select distinct start_date from calls_list where start_date >= '06/06/2012 00:00:00';
返回
06/06/2012 09:27:40
06/06/2012 09:28:08
06/06/2012 09:28:18
06/06/2012 09:29:18
31/05/2012 07:02:46
31/05/2012 07:04:22
31/05/2012 07:04:35
31/05/2012 07:08:16
我正在挠头......任何想法?我来自MSSQL背景,因此MySQL可能会以不同的方式处理日期和时间吗?
答案 0 :(得分:0)
似乎start_date
是DATETIME
字段。每一行都是不同的 - 相同的日期,但不同的时间。我建议:
select distinct DATE(start_date) from calls_list where start_date >= '06/06/2012 00:00:00';