Q
Which rule applies to a SELECT with GROUP BY?
-
A
All columns must be aggregated
-
B
GROUP BY must appear before FROM
-
C
Every non-aggregated column in SELECT must appear in GROUP BY
-
D
Only numeric columns can be grouped
Correct Answer:
C. Every non-aggregated column in SELECT must appear in GROUP BY
Explanation:
Otherwise Oracle raises ORA-00979: not a GROUP BY expression.