DBMS · SQL interview questions

54 DBMS · SQL questions from the Computer Science Fundamentals bank, written for Indian campus drives and tech interviews. Every question has a verified answer and an AI-tutor explanation on placd.

Sign up free to see every answer with its explanation and ask the AI tutor.

Practice DBMS · SQL free

1. What is DDL?

Junior
  1. A.the SQL category for managing transactions with COMMIT, ROLLBACK and SAVEPOINT
  2. B.a clause that collapses rows sharing a value into summary groups for aggregation
  3. C.the SQL category for defining schema with commands like CREATE, ALTER and DROP
  4. D.a clause that filters individual rows before any grouping is applied

Answer + AI explanation with a free account

2. Which term means: "the SQL category for defining schema with commands like CREATE, ALTER and DROP"?

Junior
  1. A.DDL
  2. B.DML
  3. C.Left outer join
  4. D.GROUP BY clause

Answer + AI explanation with a free account

3. Which statement is correct?

Junior
  1. A.DDL — the SQL category for defining schema with commands like CREATE, ALTER and DROP
  2. B.DDL — a join returning only the rows that have matching values in both tables
  3. C.DDL — a join producing the Cartesian product of every row in one table with every row in another
  4. D.DDL — a join in which a table is joined to itself to relate its own rows

Answer + AI explanation with a free account

4. What is DML?

Junior
  1. A.a join returning all rows from both tables, filling nulls where there is no match
  2. B.a join producing the Cartesian product of every row in one table with every row in another
  3. C.a subquery that references the outer query and re-executes for each outer row
  4. D.the SQL category for manipulating data with commands like INSERT, UPDATE and DELETE

Answer + AI explanation with a free account

5. Which term means: "the SQL category for manipulating data with commands like INSERT, UPDATE and DELETE"?

Junior
  1. A.DML
  2. B.Cross join
  3. C.UNION operator
  4. D.Left outer join

Answer + AI explanation with a free account

6. Which statement is correct?

Junior
  1. A.DML — a stored named query that presents data as a virtual table without physically storing it
  2. B.DML — a join returning all rows from both tables, filling nulls where there is no match
  3. C.DML — the SQL category for managing transactions with COMMIT, ROLLBACK and SAVEPOINT
  4. D.DML — the SQL category for manipulating data with commands like INSERT, UPDATE and DELETE

Answer + AI explanation with a free account

7. What is DCL?

Mid
  1. A.a join returning only the rows that have matching values in both tables
  2. B.a set operator combining two query results while keeping all duplicate rows
  3. C.a fast DDL operation that removes all rows of a table without logging each row deletion
  4. D.the SQL category for access control with GRANT and REVOKE commands

Answer + AI explanation with a free account

8. Which term means: "the SQL category for access control with GRANT and REVOKE commands"?

Mid
  1. A.Full outer join
  2. B.TCL
  3. C.Self join
  4. D.DCL

Answer + AI explanation with a free account

9. Which statement is correct?

Mid
  1. A.DCL — the SQL category for access control with GRANT and REVOKE commands
  2. B.DCL — a clause that collapses rows sharing a value into summary groups for aggregation
  3. C.DCL — a set operator combining two query results and removing duplicate rows
  4. D.DCL — a fast DDL operation that removes all rows of a table without logging each row deletion

Answer + AI explanation with a free account

10. What is TCL?

Mid
  1. A.a join returning all rows of the left table plus matching right rows, nulls where none match
  2. B.the SQL category for managing transactions with COMMIT, ROLLBACK and SAVEPOINT
  3. C.a clause that filters groups after aggregation, unlike WHERE which filters rows
  4. D.a subquery that references the outer query and re-executes for each outer row

Answer + AI explanation with a free account

11. Which term means: "the SQL category for managing transactions with COMMIT, ROLLBACK and SAVEPOINT"?

Mid
  1. A.Full outer join
  2. B.DELETE command
  3. C.UNION ALL operator
  4. D.TCL

Answer + AI explanation with a free account

12. Which statement is correct?

Mid
  1. A.TCL — the SQL category for managing transactions with COMMIT, ROLLBACK and SAVEPOINT
  2. B.TCL — the SQL category for access control with GRANT and REVOKE commands
  3. C.TCL — a join producing the Cartesian product of every row in one table with every row in another
  4. D.TCL — a fast DDL operation that removes all rows of a table without logging each row deletion

Answer + AI explanation with a free account

13. What is Inner join?

Junior
  1. A.a join returning only the rows that have matching values in both tables
  2. B.a join producing the Cartesian product of every row in one table with every row in another
  3. C.a set operator combining two query results and removing duplicate rows
  4. D.the SQL category for managing transactions with COMMIT, ROLLBACK and SAVEPOINT

Answer + AI explanation with a free account

14. Which term means: "a join returning only the rows that have matching values in both tables"?

Junior
  1. A.Inner join
  2. B.View
  3. C.DCL
  4. D.Cross join

Answer + AI explanation with a free account

15. Which statement is correct?

Junior
  1. A.Inner join — a join returning all rows of the left table plus matching right rows, nulls where none match
  2. B.Inner join — a DML operation that removes selected rows and can be rolled back
  3. C.Inner join — the SQL category for defining schema with commands like CREATE, ALTER and DROP
  4. D.Inner join — a join returning only the rows that have matching values in both tables

Answer + AI explanation with a free account

16. What is Left outer join?

Mid
  1. A.a set operator combining two query results and removing duplicate rows
  2. B.the SQL category for defining schema with commands like CREATE, ALTER and DROP
  3. C.a join returning all rows of the left table plus matching right rows, nulls where none match
  4. D.a clause that filters groups after aggregation, unlike WHERE which filters rows

Answer + AI explanation with a free account

17. Which term means: "a join returning all rows of the left table plus matching right rows, nulls where none match"?

Mid
  1. A.DCL
  2. B.Left outer join
  3. C.WHERE clause
  4. D.TCL

Answer + AI explanation with a free account

18. Which statement is correct?

Mid
  1. A.Left outer join — a clause that filters groups after aggregation, unlike WHERE which filters rows
  2. B.Left outer join — a join producing the Cartesian product of every row in one table with every row in another
  3. C.Left outer join — a set operator combining two query results while keeping all duplicate rows
  4. D.Left outer join — a join returning all rows of the left table plus matching right rows, nulls where none match

Answer + AI explanation with a free account

19. What is Full outer join?

Mid
  1. A.a join returning all rows from both tables, filling nulls where there is no match
  2. B.a stored named query that presents data as a virtual table without physically storing it
  3. C.a join returning only the rows that have matching values in both tables
  4. D.the SQL category for access control with GRANT and REVOKE commands

Answer + AI explanation with a free account

20. Which term means: "a join returning all rows from both tables, filling nulls where there is no match"?

Mid
  1. A.TRUNCATE command
  2. B.Full outer join
  3. C.View
  4. D.DDL

Answer + AI explanation with a free account

21. Which statement is correct?

Mid
  1. A.Full outer join — a set operator combining two query results while keeping all duplicate rows
  2. B.Full outer join — a join returning all rows of the left table plus matching right rows, nulls where none match
  3. C.Full outer join — a clause that filters groups after aggregation, unlike WHERE which filters rows
  4. D.Full outer join — a join returning all rows from both tables, filling nulls where there is no match

Answer + AI explanation with a free account

22. What is Cross join?

Mid
  1. A.a clause that collapses rows sharing a value into summary groups for aggregation
  2. B.a subquery that references the outer query and re-executes for each outer row
  3. C.a set operator combining two query results and removing duplicate rows
  4. D.a join producing the Cartesian product of every row in one table with every row in another

Answer + AI explanation with a free account

23. Which term means: "a join producing the Cartesian product of every row in one table with every row in another"?

Mid
  1. A.HAVING clause
  2. B.DML
  3. C.Left outer join
  4. D.Cross join

Answer + AI explanation with a free account

24. Which statement is correct?

Mid
  1. A.Cross join — a clause that filters groups after aggregation, unlike WHERE which filters rows
  2. B.Cross join — a subquery that references the outer query and re-executes for each outer row
  3. C.Cross join — a join producing the Cartesian product of every row in one table with every row in another
  4. D.Cross join — the SQL category for defining schema with commands like CREATE, ALTER and DROP

Answer + AI explanation with a free account

25. What is Self join?

Mid
  1. A.a stored named query that presents data as a virtual table without physically storing it
  2. B.a join in which a table is joined to itself to relate its own rows
  3. C.a set operator combining two query results and removing duplicate rows
  4. D.a clause that filters groups after aggregation, unlike WHERE which filters rows

Answer + AI explanation with a free account

26. Which term means: "a join in which a table is joined to itself to relate its own rows"?

Mid
  1. A.Self join
  2. B.HAVING clause
  3. C.Correlated subquery
  4. D.WHERE clause

Answer + AI explanation with a free account

27. Which statement is correct?

Mid
  1. A.Self join — a join in which a table is joined to itself to relate its own rows
  2. B.Self join — a join returning all rows from both tables, filling nulls where there is no match
  3. C.Self join — a clause that filters groups after aggregation, unlike WHERE which filters rows
  4. D.Self join — the SQL category for access control with GRANT and REVOKE commands

Answer + AI explanation with a free account

28. What is WHERE clause?

Junior
  1. A.a join in which a table is joined to itself to relate its own rows
  2. B.a clause that filters individual rows before any grouping is applied
  3. C.a clause that collapses rows sharing a value into summary groups for aggregation
  4. D.a set operator combining two query results while keeping all duplicate rows

Answer + AI explanation with a free account

29. Which term means: "a clause that filters individual rows before any grouping is applied"?

Junior
  1. A.WHERE clause
  2. B.DDL
  3. C.GROUP BY clause
  4. D.DML

Answer + AI explanation with a free account

30. Which statement is correct?

Junior
  1. A.WHERE clause — a join in which a table is joined to itself to relate its own rows
  2. B.WHERE clause — a clause that filters individual rows before any grouping is applied
  3. C.WHERE clause — the SQL category for managing transactions with COMMIT, ROLLBACK and SAVEPOINT
  4. D.WHERE clause — the SQL category for manipulating data with commands like INSERT, UPDATE and DELETE

Answer + AI explanation with a free account

Showing 30 of 54 DBMS · SQL questions — the full set, with answers, explanations and an AI tutor on every question, is inside.

Free to start

Answers, AI explanations, and a free readiness check

Sign up free to check your answers with explanations, ask the AI tutor anything on any question, and take the free 2-minute readiness check for a scored result. One full AI mock interview, scored like a real panel, is free when you sign up.

Practice DBMS · SQL free
24,000+ questions & coding problemsSoftware & IT16,274 questionsGovernment jobs26 examsAptitudenew questions every timeAI practice interviewwith feedback65 topics to practiseMechanical1,149 questionsGATE ME9 papersEngineering Mathematics381 questions2-minute checkfreeDSA Problems1,422Civil1,005 questionsGATE CE9 papersCS Fundamentals1,209 questionsYour scores6 skillsSystem Design25Electrical / EEE1,047 questionsGATE EE9 papersRun your codeC++ · Java · PythonLow-Level Design144Electronics & Comm.975 questionsGATE EC9 papersAI help on every questionFull-Stack6,282Chemical1,005 questionsGATE CH9 papersAI whiteboardsystem designWork abroadEurope · remote · transfersESE ME1 paperGATE practice papers2019–2026ESE CE1 paperDate alertsbefore the last dateESE EE1 paperBehavioural courseHR round practiceESE ET1 paperResume optimizerProSSC JE ME1 paperApplication trackerSSC JE CE1 paperCompany-wise prepSSC JE EE1 paperRole roadmapsRRB JE1 subjectPriced in ₹UPI · cardsISRO SC1 paperGATE CS9 papersIBPS SO IT1 paperUGC NET CS1 paperSSC CGL26 papersIBPS PO26 papersRRB NTPC26 papersSSC CHSL26 papersIBPS Clerk26 papersSBI Clerk26 papersRRB Group D26 papersSSC CPO26 papersSSC GD26 papers