Database Management System (DBMS) MCQs
1. What is the full form of DBMS?
DBMS stands for Database Management System, software used to define, manipulate, retrieve and manage data.
2. Which of the following is NOT a function of the DBMS?
Process management is typically a function of the Operating System, not the DBMS.
3. What is information about data called?
Metadata is data that describes other data, providing information about a certain item's content.
4. Which level of abstraction describes how data is stored in the database?
The physical level is the lowest level of abstraction and describes complex low-level data structures in detail.
5. In the relational model, a row is referred to as a:
In relational database theory, a row in a table is called a tuple.
6. Which of the following is used to define the structure of the database?
DDL (Data Definition Language) commands like CREATE, ALTER, and DROP are used to define the database schema.
7. The ability to modify the schema at one level without affecting the schema at the next higher level is called:
Data independence is a major advantage of DBMS, allowing changes in one level (e.g., physical) without affecting others (e.g., logical).
8. Which key is used to uniquely identify a record in a table?
A Primary Key is a minimal set of attributes that uniquely identifies a tuple in a relation.
9. A set of one or more attributes that, taken collectively, allows us to identify uniquely a tuple in the relation is called a:
A super key is the most general type of unique identifier. A candidate key is a minimal super key.
10. Which command is used to remove a table and all its data from the database?
The DROP command removes the table definition and all its data. DELETE only removes data rows.
11. In an ER diagram, an entity is represented by a:
Rectangles represent entity sets in ER diagrams.
12. Which normal form is based on the concept of functional dependency?
1NF, 2NF, and 3NF all deal with functional dependencies to varying degrees (atomicity, partial dependency, transitive dependency).
13. A relation is in BCNF if:
Boyce-Codd Normal Form (BCNF) requires that for every functional dependency X -> Y, X must be a super key (candidate key).
14. Which ACID property ensures that a transaction is either fully completed or not occurred at all?
Atomicity follows the "all or nothing" rule for transactions.
15. The 'D' in ACID stands for:
Durability ensures that once a transaction is committed, its effects are permanent even in case of system failure.
16. Which SQL keyword is used to retrieve unique values?
The SELECT DISTINCT statement is used to return only distinct (different) values.
17. Which of the following is an aggregate function in SQL?
AVG, COUNT, MAX, MIN, and SUM are all standard SQL aggregate functions.
18. A "Foreign Key" constraint is used to enforce:
Foreign keys ensure that a value in one table corresponds to a valid existing record in another table (or the same table).
19. Which operation performs a set union of two relations?
The UNION operator combines the result-set of two or more SELECT statements.
20. Which component of the DBMS controls concurrency?
The Scheduler (or Lock Manager/Concurrency Control Manager) ensures that concurrent transactions are executed without conflicts.
21. In the ER model, a "Weak Entity" is represented by:
A weak entity, which cannot be identified by its own attributes alone, is represented by a double-outlined rectangle.
22. Which SQL command is used to change data in a database table?
The UPDATE command is used to modify existing records in a table. ALTER is for changing the table structure.
23. A Schedule is said to be serializable if:
Serializability checks if a concurrent schedule produces the same result as some serial execution of the same transactions.
24. Which join returns all rows from the left table, and the matched rows from the right table?
A LEFT JOIN (or LEFT OUTER JOIN) returns all records from the left table and the matched records from the right table.
25. The process of minimizing redundancy and dependency in a database is called:
Normalization involves organizing data in a database to reduce redundancy and improve data integrity.
26. Which symbol is used for the "Select" operation in Relational Algebra?
Sigma (σ) represents the Selection operation, which filters rows based on a condition. Pi (π) is for Projection.
27. A deadlock exists when:
Deadlock occurs when two or more transactions are waiting indefinitely for one another to give up locks.
28. Which of the following is a DCL command?
DCL (Data Control Language) includes GRANT and REVOKE, which manage user permissions.
29. Which level of RAID provides disk mirroring?
RAID 1 mirrors data across two or more disks to provide redundancy.
30. What is a "View" in SQL?
A view contains no data itself but is a stored query that presents data from other tables.
31. Which clause is used to sort the result set?
ORDER BY is used to sort the result-set in ascending or descending order.
32. The "wildcard" character used with the LIKE operator to represent zero, one, or multiple characters is:
The percent sign (%) represents zero, one, or multiple characters. The underscore (_) represents a single character.
33. Which protocol is used for concurrency control to prevent deadlock?
Various protocols like 2PL, Timestamp Ordering, and Graph-Based protocols are used to manage concurrency.
34. B+ Trees are used for:
B+ Trees are a balanced tree data structure widely used for database indexing.
35. Which attribute cannot contain NULL values?
Primary keys must contain unique values and cannot contain NULLs (Entity Integrity Rule).
36. A relationship where one record in Table A relates to many records in Table B is:
An example is one Customer having many Orders.
37. What does the HAVING clause do?
The HAVING clause is used to filter records that work on summarized GROUP BY results.
38. Which type of failure occurs due to power loss or hardware malfunction?
System crashes (soft crashes) affect the contents of volatile storage (RAM) but not non-volatile storage.
39. Checkpoints are used for:
Checkpoints reduce the amount of work required during a database recovery process by limiting how far back the log must be scanned.
40. The result of a Cartesian product of two tables with 5 rows and 4 rows respectively will have how many rows?
A Cartesian product (CROSS JOIN) returns the product of the number of rows in the two tables (5 * 4 = 20).