27 Schema & DDL questions from the SQL bank, written for Indian campus drives and tech interviews. Every question has a verified answer and an AI-tutor explanation on placd.
Free to start: the 2-minute IT readiness check — six questions and a result.
A.a Postgres pseudo-type that auto-generates increasing integer keys, equivalent in purpose to MySQL AUTO_INCREMENT and standard IDENTITY columns
B.a DDL statement that defines a new relation by specifying its column names, data types, and constraints
C.a DDL statement that changes an existing table's structure, such as adding a column, dropping a column, or modifying a constraint
D.a rule that validates each row against a boolean condition and rejects any row for which the condition is false
Answer + AI explanation with Pro
2. Which term means: "a DDL statement that defines a new relation by specifying its column names, data types, and constraints"?
Junior
A.foreign key
B.CHECK constraint
C.CREATE TABLE
D.SERIAL
Answer + AI explanation with Pro
3. Which statement is correct?
Junior
A.CREATE TABLE — a column constraint that forbids the absence of a value, forcing every row to supply something for that column
B.CREATE TABLE — a DDL statement that defines a new relation by specifying its column names, data types, and constraints
C.CREATE TABLE — a rule guaranteeing no two rows share the same value in the specified column(s), while still permitting NULLs in most engines
D.CREATE TABLE — a column clause supplying a fallback value automatically used when an insert omits that column
Answer + AI explanation with Pro
4. What is ALTER TABLE?
Junior
A.a column clause supplying a fallback value automatically used when an insert omits that column
B.a DDL statement that changes an existing table's structure, such as adding a column, dropping a column, or modifying a constraint
C.a DDL statement that defines a new relation by specifying its column names, data types, and constraints
D.a rule guaranteeing no two rows share the same value in the specified column(s), while still permitting NULLs in most engines
Answer + AI explanation with Pro
5. Which term means: "a DDL statement that changes an existing table's structure, such as adding a column, dropping a column, or modifying a constraint"?
Junior
A.foreign key
B.ALTER TABLE
C.DEFAULT
D.primary key
Answer + AI explanation with Pro
6. Which statement is correct?
Junior
A.ALTER TABLE — a column constraint that forbids the absence of a value, forcing every row to supply something for that column
B.ALTER TABLE — a constraint identifying each row uniquely; it forbids duplicate values and forbids NULLs, and a table may have only one
C.ALTER TABLE — a DDL statement that changes an existing table's structure, such as adding a column, dropping a column, or modifying a constraint
D.ALTER TABLE — a DDL statement that defines a new relation by specifying its column names, data types, and constraints
Answer + AI explanation with Pro
7. What is primary key?
Junior
A.a Postgres pseudo-type that auto-generates increasing integer keys, equivalent in purpose to MySQL AUTO_INCREMENT and standard IDENTITY columns
B.a constraint identifying each row uniquely; it forbids duplicate values and forbids NULLs, and a table may have only one
C.a rule guaranteeing no two rows share the same value in the specified column(s), while still permitting NULLs in most engines
D.a rule that validates each row against a boolean condition and rejects any row for which the condition is false
Answer + AI explanation with Pro
8. Which term means: "a constraint identifying each row uniquely; it forbids duplicate values and forbids NULLs, and a table may have only one"?
Junior
A.UNIQUE constraint
B.NOT NULL
C.SERIAL
D.primary key
Answer + AI explanation with Pro
9. Which statement is correct?
Junior
A.primary key — a constraint identifying each row uniquely; it forbids duplicate values and forbids NULLs, and a table may have only one
B.primary key — a column clause supplying a fallback value automatically used when an insert omits that column
C.primary key — a DDL statement that changes an existing table's structure, such as adding a column, dropping a column, or modifying a constraint
D.primary key — a column constraint that forbids the absence of a value, forcing every row to supply something for that column
Answer + AI explanation with Pro
10. What is foreign key?
Mid
A.a Postgres pseudo-type that auto-generates increasing integer keys, equivalent in purpose to MySQL AUTO_INCREMENT and standard IDENTITY columns
B.a constraint enforcing referential integrity by requiring a column's values to match an existing key in another (or the same) table
C.a DDL statement that changes an existing table's structure, such as adding a column, dropping a column, or modifying a constraint
D.a rule that validates each row against a boolean condition and rejects any row for which the condition is false
Answer + AI explanation with Pro
11. Which term means: "a constraint enforcing referential integrity by requiring a column's values to match an existing key in another (or the same) table"?
Mid
A.DEFAULT
B.primary key
C.foreign key
D.NOT NULL
Answer + AI explanation with Pro
12. Which statement is correct?
Mid
A.foreign key — a column clause supplying a fallback value automatically used when an insert omits that column
B.foreign key — a constraint enforcing referential integrity by requiring a column's values to match an existing key in another (or the same) table
C.foreign key — a DDL statement that changes an existing table's structure, such as adding a column, dropping a column, or modifying a constraint
D.foreign key — a column constraint that forbids the absence of a value, forcing every row to supply something for that column
Answer + AI explanation with Pro
13. What is UNIQUE constraint?
Mid
A.a rule guaranteeing no two rows share the same value in the specified column(s), while still permitting NULLs in most engines
B.a DDL statement that defines a new relation by specifying its column names, data types, and constraints
C.a rule that validates each row against a boolean condition and rejects any row for which the condition is false
D.a constraint identifying each row uniquely; it forbids duplicate values and forbids NULLs, and a table may have only one
Answer + AI explanation with Pro
14. Which term means: "a rule guaranteeing no two rows share the same value in the specified column(s), while still permitting NULLs in most engines"?
Mid
A.UNIQUE constraint
B.CHECK constraint
C.CREATE TABLE
D.ALTER TABLE
Answer + AI explanation with Pro
15. Which statement is correct?
Mid
A.UNIQUE constraint — a rule guaranteeing no two rows share the same value in the specified column(s), while still permitting NULLs in most engines
B.UNIQUE constraint — a Postgres pseudo-type that auto-generates increasing integer keys, equivalent in purpose to MySQL AUTO_INCREMENT and standard IDENTITY columns
C.UNIQUE constraint — a constraint enforcing referential integrity by requiring a column's values to match an existing key in another (or the same) table
D.UNIQUE constraint — a column clause supplying a fallback value automatically used when an insert omits that column
Answer + AI explanation with Pro
16. What is CHECK constraint?
Mid
A.a rule that validates each row against a boolean condition and rejects any row for which the condition is false
B.a constraint identifying each row uniquely; it forbids duplicate values and forbids NULLs, and a table may have only one
C.a column clause supplying a fallback value automatically used when an insert omits that column
D.a constraint enforcing referential integrity by requiring a column's values to match an existing key in another (or the same) table
Answer + AI explanation with Pro
17. Which term means: "a rule that validates each row against a boolean condition and rejects any row for which the condition is false"?
Mid
A.foreign key
B.CHECK constraint
C.NOT NULL
D.DEFAULT
Answer + AI explanation with Pro
18. Which statement is correct?
Mid
A.CHECK constraint — a rule guaranteeing no two rows share the same value in the specified column(s), while still permitting NULLs in most engines
B.CHECK constraint — a rule that validates each row against a boolean condition and rejects any row for which the condition is false
C.CHECK constraint — a Postgres pseudo-type that auto-generates increasing integer keys, equivalent in purpose to MySQL AUTO_INCREMENT and standard IDENTITY columns
D.CHECK constraint — a column clause supplying a fallback value automatically used when an insert omits that column
Answer + AI explanation with Pro
19. What is NOT NULL?
Junior
A.a column constraint that forbids the absence of a value, forcing every row to supply something for that column
B.a rule guaranteeing no two rows share the same value in the specified column(s), while still permitting NULLs in most engines
C.a DDL statement that defines a new relation by specifying its column names, data types, and constraints
D.a constraint enforcing referential integrity by requiring a column's values to match an existing key in another (or the same) table
Answer + AI explanation with Pro
20. Which term means: "a column constraint that forbids the absence of a value, forcing every row to supply something for that column"?
Junior
A.NOT NULL
B.ALTER TABLE
C.primary key
D.SERIAL
Answer + AI explanation with Pro
21. Which statement is correct?
Junior
A.NOT NULL — a column constraint that forbids the absence of a value, forcing every row to supply something for that column
B.NOT NULL — a rule guaranteeing no two rows share the same value in the specified column(s), while still permitting NULLs in most engines
C.NOT NULL — a Postgres pseudo-type that auto-generates increasing integer keys, equivalent in purpose to MySQL AUTO_INCREMENT and standard IDENTITY columns
D.NOT NULL — a rule that validates each row against a boolean condition and rejects any row for which the condition is false
Answer + AI explanation with Pro
22. What is DEFAULT?
Mid
A.a DDL statement that defines a new relation by specifying its column names, data types, and constraints
B.a column clause supplying a fallback value automatically used when an insert omits that column
C.a column constraint that forbids the absence of a value, forcing every row to supply something for that column
D.a constraint enforcing referential integrity by requiring a column's values to match an existing key in another (or the same) table
Answer + AI explanation with Pro
23. Which term means: "a column clause supplying a fallback value automatically used when an insert omits that column"?
Mid
A.DEFAULT
B.primary key
C.CHECK constraint
D.SERIAL
Answer + AI explanation with Pro
24. Which statement is correct?
Mid
A.DEFAULT — a DDL statement that changes an existing table's structure, such as adding a column, dropping a column, or modifying a constraint
B.DEFAULT — a rule guaranteeing no two rows share the same value in the specified column(s), while still permitting NULLs in most engines
C.DEFAULT — a DDL statement that defines a new relation by specifying its column names, data types, and constraints
D.DEFAULT — a column clause supplying a fallback value automatically used when an insert omits that column
Answer + AI explanation with Pro
25. What is SERIAL?
Senior
A.a column constraint that forbids the absence of a value, forcing every row to supply something for that column
B.a Postgres pseudo-type that auto-generates increasing integer keys, equivalent in purpose to MySQL AUTO_INCREMENT and standard IDENTITY columns
C.a constraint identifying each row uniquely; it forbids duplicate values and forbids NULLs, and a table may have only one
D.a constraint enforcing referential integrity by requiring a column's values to match an existing key in another (or the same) table
Answer + AI explanation with Pro
26. Which term means: "a Postgres pseudo-type that auto-generates increasing integer keys, equivalent in purpose to MySQL AUTO_INCREMENT and standard IDENTITY columns"?
Senior
A.SERIAL
B.DEFAULT
C.foreign key
D.CHECK constraint
Answer + AI explanation with Pro
27. Which statement is correct?
Senior
A.SERIAL — a column clause supplying a fallback value automatically used when an insert omits that column
B.SERIAL — a Postgres pseudo-type that auto-generates increasing integer keys, equivalent in purpose to MySQL AUTO_INCREMENT and standard IDENTITY columns
C.SERIAL — a constraint identifying each row uniquely; it forbids duplicate values and forbids NULLs, and a table may have only one
D.SERIAL — a DDL statement that changes an existing table's structure, such as adding a column, dropping a column, or modifying a constraint
Answer + AI explanation with Pro
Free to start
Start with a free readiness check
Sign up free for the 2-minute IT readiness check and a scored result. Answers, explanations and the AI tutor on every Schema & DDL question come with Pro.