关于图表分类排序问题

能不能对那个分类进行排序?
sql语句如下:
正确顺序:1,2,3,18,19,4,5,6,7


  1. select sum(case DrawingType when 1 then 1 else 0 end) as '图纸CAD',
  2. sum(case DrawingType when 0 then 1 else 0 end) as '图纸2020',
  3. sum(case DrawingType when 2 then 1 else 0 end) as '其他',
  4. COUNT(OrderNo) as '总量',
  5. (case OrderStatus
  6. when 1 then '待受理'
  7. when 2 then '待审图'
  8. when 3 then '待拆单'
  9. when 4 then '待报价审核'
  10. when 5 then '待经销商付款'
  11. when 6 then '待付款确认'
  12. when 7 then '待计划接单'
  13. when 18 then '待料单审核'
  14. when 19 then '待孔位审核' end) as '分类'
  15. from dbo.C_Order
  16. where 1=1
  17. ${if(len(ordertype)=0,""," and OrderType in ("+ordertype+")")}
  18. ${if(len(OrderStatus)=0,"and OrderStatus in (1,2,3,4,5,6,7,18,19)"," and OrderStatus in ("+OrderStatus+")")}
  19. group by OrderStatus
复制代码

FineReport何必管一片海 发布于 2017-1-6 16:57
悬赏:2 F币 + 添加悬赏
提示:增加悬赏、完善问题、追问等操作,可使您的问题被置顶,并向所有关注者发送通知
共1回答
最佳回答
0
hbyanghua发布于2017-1-6 16:57(编辑于 2023-9-6 09:34)
555
  • 0关注人数
  • 543浏览人数
  • 最后回答于:2017-1-6 16:57
    活动推荐 更多
    热门课程 更多
    返回顶部