本地设计器预览报表月份是正常升序排列得到,但是挂到服务器上之后月份就错乱了,SQL执行的结果也是正常升序的,可能是哪里影响到了呢? 附上SQL: select t.物料编码 as item_code, decode(t.组织,'HD1','宝鸡','HD2','西安','HD3','三期','HD5','铜川') as org, t.物料名称 as item_name, case when to_char(t.出库日期,'DD')>'28' then to_char(t.出库日期+5,'YYYY-MM') else to_char(t.出库日期,'YYYY-MM') end as dates from hdcg.cux_zhuchi_materials_out t where to_char(t.出库日期,'YYYY-MM-DD') between to_char(add_months(to_date('2023-02-08','YYYY-MM-DD'),-25),'YYYY-MM')||'-29' and '2023-02-08' and t.供应商编码='SD052800004' group by t.物料编码,t.组织, t.物料名称, t.出库日期 order by t.出库日期,decode(t.组织,'HD1','宝鸡','HD2','西安','HD3','三期','HD5','铜川') |