oracle根据条件统计各组记录数量
1. 根据具体条件统计这批数据落到每组的数量 select to_char(TIMESTAMP, 'yyyy-mm-dd') column1, column2, column3, count(CASE WHEN DURATION<30*60 THEN 1 END) less30, count(CASE WHEN DURATION>=30*60 and DURATION<60*60*1000 THEN 1 END) more30less60, count(CASE WHEN DURATION>=60*60 and...
more...