|
SQL> select count(*)c,count(case when x=0 then 1 end)c0,
2 count(case when x>0 then 1 end)c1,
3 count(case when x<0 then 1 end)c2
4 from
5 (
6 select /*+parallel (hu,12) parallel(ren,12)*/
7 hu.id, min(h031+h032)-count(r01) x from huc hu,renc ren
8 where hu.id=ren.id
9 group by hu.id
10 )a;
C C0 C1 C2
---------- ---------- ---------- ----------
351233698 351045346 0 0
已用时间: 00: 22: 59.46 |
|