木棉

导航

2012年4月19日

SQL ORDER BY 排序

摘要: 当一个物料表中有物料编码和数量时,我们需要将数量为0的放在最后,然后数量大于0的按物料编码排序select new_partcode,new_siteinvqty from new_srv_sitelocationinvorder by case new_siteinvqty when '0' then '0' else '1' end desc,new_partcode asc物料编码 数量1101-03123 21101-03707 21104-00975 31104-00975 21104-01061 39601-14733 09601-1 阅读全文

posted @ 2012-04-19 14:05 木棉 阅读(227) 评论(0) 推荐(0)