Discussion
The SQL keyword GROUP BY instructs the DBMS to group together those rows that have the same value in a column.
Answer: A
Correct answer: True
GROUP BY collects rows sharing the same value in the named column or columns into a single group, and the aggregate functions in the SELECT list are then computed once per group.
Two rules follow. Every column in the SELECT list must either appear in the GROUP BY or be inside an aggregate, since anything else has no single value per group. And filtering on the aggregates belongs in HAVING, which runs after the grouping, rather than in WHERE, which runs before it.
No comment is present. Be the first to comment.
Loading…
Post your comment
Please log in or register to post a comment.
Examination Categories
- SSC Exams
- Banking Exams
- Teaching Exams
- Civil Services Exams
- Railways Exams
- Engineering Recruitment Exams
- Defence Exams
- State Government Exams
- Police Exams
- Insurance Exams
- Nursing Exams
- Other Government Exams
- NRA CET
- PG Entrance Exams
- Campus Placement
- MBA Entrance Exams
- CUET and UG Entrance
- Judiciary Exams
- Regulatory Body Exams
- Software Development