结构表:

date                   text
2014-11-01 12:23   test words
2014-11-01 12:23   test words
2014-11-02 12:23   test words
2014-11-01 12:23   test words
2014-11-03 12:23   test words
2014-11-01 12:23   test words
2014-11-04 12:23   test words
2014-11-04 12:23   test words
2014-11-07 12:23   test words



SELECT * FROM TABLE GROUP by date

但此查询不是以dd-mm-YY格式获取唯一日期。。。
请告诉我如何从这个表中获得唯一的日期dd-mm-YY?
备注:结果应该是下一个:
2014-11-07
2014-11-04
2014-11-03
2014-11-02
2014-11-01

最佳答案

SELECT DISTINCT DATE(date) FROM table;

10-07 13:01
查看更多