sql语句书写升降序

1, desc:降序,明天今天昨天,zyx...cba,.....321  

  sql语句:select * from SC_BackDiggingInfo where WriteDate<='2013-08-31' order by WriteDate  desc

  例如:      

WriteDate
2013-08-28 00:00:00.000
2013-08-27 00:00:00.000
2013-08-26 00:00:00.000
2013-08-25 00:00:00.000
2013-08-24 00:00:00.000
2013-08-23 00:00:00.000
2013-08-22 00:00:00.000

2, asc: 升序,昨天今天明天,abc...xyz,123......   

  sql语句:select * from SC_BackDiggingInfo where WriteDate<='2013-08-31' order by WriteDate  asc

  例如:

WriteDate
2013-08-22 00:00:00.000
2013-08-23 00:00:00.000
2013-08-24 00:00:00.000
2013-08-25 00:00:00.000
2013-08-26 00:00:00.000
2013-08-27 00:00:00.000
2013-08-28 00:00:00.000
posted @ 2013-10-12 10:37  namehwh  阅读(3416)  评论(0编辑  收藏  举报