Hi,
I'm looking for a way to clean my SQL Statement.
The statement is like this:
SELECT CASE WHEN(...), COUNT(*) FROM ...
GROUP BY CASE WHEN(...)
Is there a way write the same statement Oracle (10g) with a nicer GROUP BY, e.g. GROUP BY col_1?
Alias are only valid on ORDER BY, not GROUP BY and Google did not return helping results for
'oracle "group by" column number'
Thanks a lot,
Blama