2011-01-24 157 views
0

我在我的表中有一个名为date1的日期字段。如果我使用下面的查询。Mysql按日期排序

select * from schedule order by date1 asc 

it gives the result like as jan 2011 comes before december 2010. but i need the december 2011 as the first row of the result. 

回答

1

查询更改为

SELECT * FROM schedule ORDER BY date1 DESC

这应该做的伎俩。

James

0
select * from schedule order by date1 desc