What is the purpose of the SQL GROUP BY ... HAVING combination? MCQ with Answer and Explanation

What is the purpose of the SQL GROUP BY ... HAVING combination?
A. To filter groups based on aggregate values
B. To sort groups
C. To select individual rows
D. To join groups
Answer: Option A
Solution (By JKSSB Mock Tests)
HAVING is used in conjunction with GROUP BY to filter groups based on conditions applied to aggregate functions.

Discuss this Question (0)

No comments yet. Be the first to start the discussion!

Practice More Database Management System (DBMS) Questions

Question #1
In an Entity-Relationship (ER) diagram, what geometric shape is used to represent an entity type?
A. Triangle
B. Ellipse
C. Rectangle
D. Diamond

Correct Answer: Option C


Explanation:
In standard ER modeling notation, rectangles are used to represent entity sets or entity types.

This question belongs to: Computer Database Management System (DBMS)
Question #2
Which of the following is an example of a relational database management system (RDBMS)?
A. Redis
B. Cassandra
C. Oracle Database
D. MongoDB

Correct Answer: Option C


Explanation:
Oracle Database is a well-known RDBMS. MongoDB, Redis, and Cassandra are NoSQL databases.

This question belongs to: Computer Database Management System (DBMS)
Question #3
Which of the following is a DML statement?
A. UPDATE
B. CREATE
C. ALTER
D. DROP

Correct Answer: Option A


Explanation:
UPDATE is a Data Manipulation Language (DML) command used to modify existing records in a table. CREATE, ALTER, DROP are DDL.

This question belongs to: Computer Database Management System (DBMS)