15900334107(提问者)SELECT to_char(sale.xsdate,\'hh24\') as 时段,sum(sale.sstotal) as 销售金额,count(1) as 客流 from tsalsale sale WHERE orgcode=\'0008\' and trantype<>5
group by to_char(sale.xsdate,\'hh24\') order by to_char(sale.xsdate,\'hh24\')
嘿嘿,oracle不识别hour() 换成to_char可以了 感谢