iGET

Database (DBMS) - MCQ Practice Questions

DBMS & SQL MCQs — normalization, joins, transactions & indexing.

57 questions | 100% Free

Q.1Medium

What is the purpose of the JOIN clause in SQL?

Q.2Medium

Which type of JOIN returns only matching rows from both tables?

Q.3Medium

Which SQL clause is used to sort the result set in ascending or descending order?

Q.4Medium

What is the difference between WHERE and HAVING clauses?

Q.5Medium

What will be the result of this query: SELECT * FROM employees WHERE salary > 50000 AND department = 'IT';

Q.6Medium

Which SQL function is used to count non-NULL values in a column?

Q.7Medium

What does the PRIMARY KEY constraint ensure?

Q.8Medium

Which of the following SQL wildcards matches any single character?

Q.9Medium

Which SQL statement is used to delete all records from a table without removing the table structure?

Q.10Medium

Which aggregate function ignores NULL values by default?

Q.11Medium

Given a table 'employees' with salary column, which query finds employees earning more than average salary?

Q.12Medium

What is the difference between CROSS JOIN and INNER JOIN?

Q.13Medium

Which statement correctly uses aliases in SQL?

Q.14Medium

For a query with transactions table, which index type is most efficient for WHERE clauses checking transaction_date range?

Q.15Medium

What is the output of: SELECT COALESCE(NULL, NULL, 'SQL', 'Database');?

Q.16Medium

In a normalized database following 3NF, which anomaly is prevented?

Q.17Medium

Which of the following queries demonstrates a self-join correctly?

Q.18Medium

In a bank database with accounts and transactions tables, to find accounts with transactions greater than 100,000, which clause must follow GROUP BY?

Q.19Medium

What will be the result of: SELECT in SQL?

Q.20Medium

A company table has 500K employee records. To find employees with salary > 50,000 efficiently, which strategy is optimal?