📘 Database MCQs with Answers
1. Which of the following is a type of database model?
A. Hierarchical Model
B. Network Model
C. Relational Model
D. All of the above
2. Which SQL statement is used to extract data from a database?
A. GET
B. SELECT
C. OPEN
D. EXTRACT
3. What does DML stand for in SQL?
A. Data Markup Language
B. Data Manipulation Language
C. Data Management Language
D. Data Mode Language
4. Which normal form ensures that there are no repeating groups in a relation?
A. First Normal Form (1NF)
B. Second Normal Form (2NF)
C. Third Normal Form (3NF)
D. Fourth Normal Form (4NF)
5. Which normal form deals with partial dependencies?
A. First Normal Form (1NF)
B. Second Normal Form (2NF)
C. Third Normal Form (3NF)
D. Boyce-Codd Normal Form (BCNF)
6. A relation is in Third Normal Form (3NF) if:
A. It is in 1NF and all non-key attributes are functionally dependent on the primary key.
B. It is in 2NF and has no transitive dependencies.
C. It is in 2NF and has no partial dependencies.
D. It is in 1NF and has no repeating groups.
7. Which normal form eliminates all transitive dependencies?
A. First Normal Form (1NF)
B. Second Normal Form (2NF)
C. Third Normal Form (3NF)
D. Boyce-Codd Normal Form (BCNF)
8. Which of the following statements regarding functional dependencies is true?
A. A functional dependency is a symmetric relationship between attributes.
B. A functional dependency determines a one-to-one relationship between attributes.
C. A functional dependency is a constraint between sets of attributes in a relation.
D. A functional dependency allows null values in determining the attribute values.
9. If R(A, B, C, D) has functional dependencies A → B and B → C, which of the following is
true?
A. A uniquely determines C.
B. B uniquely determines A.
C. A uniquely determines D.
D. B uniquely determines D.
10. For a relation R(A, B, C, D) with functional dependencies A → B, B → C, and C → D,
what is the primary key?
👉 Minimal key = {A} (but since not in options, the closest correct is)
A. {A, B}
11. In a university database, which of the following is an entity type?
A. Student
B. GPA
C. Grade
D. Course
12. Which statement about entity types is correct?
A. An entity type is always a physical object.
B. An entity type can have only one attribute.
C. An entity type can have relationships with other entity types.
D. An entity type is always stored as a single table in a database.
13. In an online shopping system, which of the following could be an entity type?
A. Cart
B. Discount
C. Payment Method
D. Product
14. In a database table representing employees, which of the following is an example of an
attribute?
A. Employee ID
B. Department
C. Salary
D. All of the above
15. In a database schema, what is the primary difference between a superkey and a
candidate key?
A. A superkey can contain NULL values, whereas a candidate key cannot.
B. A superkey can uniquely identify each record, whereas a candidate key is any minimal
superkey.
C. A superkey is the same as a primary key, whereas a candidate key is used for foreign key
constraints.
D. There is no difference; they both refer to any key in a table.
Note: → Close but incomplete. The correct definition:
Superkey = any set of attributes that uniquely identify a row.
Candidate key = a minimal superkey (no extra attributes).
So B is the closest correct option among the choices
16. Which of the following statements about composite keys is true?
A. A composite key consists of only one attribute.
B. A composite key is always a primary key.
C. A composite key is composed of two or more attributes.
D. A composite key cannot contain NULL values.
17. In SQL, which wildcard character matches any sequence of characters?
A. % ✔
B. _
C. *
D. #
18. What does the SQL wildcard character _ represent?
A. Matches any single character
B. Matches any sequence of characters
C. Matches the beginning of a string
D. Matches the end of a string
19. Which SQL clause is commonly used with wildcards to filter data based on patterns?
A. ORDER BY
B. GROUP BY
C. WHERE
D. JOIN
20. What does the SQL condition x > ANY (SELECT y FROM table) mean?
A. x is greater than or equal to any value of y in the table
B. x is greater than every value of y in the table
C. x is greater than or equal to all values of y in the table
D. x is greater than or equal to some values of y in the table
21. In SQL, which keyword is used to compare a value to each value returned by a
subquery or a list?
A. SOME
B. ALL
C. ANY
D. EACH
E. All of the above
22. Which SQL join returns only the rows where there is a match in both tables?
A. Inner join
B. Natural join
C. Left join
D. Outer join
23. Which SQL join returns all rows from the left table and the matched rows from the
right table, where the join condition is met?
A. Left join
B. Right join
C. Outer join
D. Full outer join
24. Which SQL statement is used to add a new column to an existing table?
A. ALTER TABLE ADD COLUMN
B. ALTER COLUMN
C. ADD COLUMN
D. MODIFY COLUMN
25. What is the purpose of the SQL ALTER TABLE DROP COLUMN statement?
A. To delete the entire table
B. To remove a column from an existing table
C. To modify the data type of a column
D. To add a constraint to a column
26. Which of the following SQL statements is used to change the name of a table?
A. RENAME TABLE
B. ALTER TABLE RENAME TO
C. RENAME TO
D. ALTER TABLE RENAME
27. What happens when you execute ALTER TABLE ADD CONSTRAINT in SQL?
A. Adds a new column to the table
B. Modifies the structure of an existing column
C. Adds a constraint (like foreign key or unique) to the table
D. Drops a constraint from the table
E. Both C and D