Database Management System (DBMS) MCQs

Computer

Database Management System (DBMS) MCQs

Practice DBMS MCQs covering database, data, information, DBMS, RDBMS and SQL basics with answers and explanations.

278
Total Questions

Practice Questions

Page 14 of 14
Question #261
Which condition-tester returns TRUE if a subquery returns one or more records, and FALSE if the subquery returns no rows?
A. ANY
B. IN
C. ALL
D. EXISTS

Correct Answer: Option D


Explanation:
The EXISTS operator is used to test for the presence of any records in a subquery, returning TRUE as soon as a single matching row is encountered.

This question belongs to: Computer Database Management System (DBMS)
Question #262
The intentional process of introducing redundant data into a normalized database structure to optimize read query performance is called what?
A. Denormalization
B. Normalization
C. Decomposition
D. Fragmentation

Correct Answer: Option A


Explanation:
Denormalization is a strategy applied to normalized databases where redundant data is selectively added to speed up complex read queries by minimizing costly table joins.

This question belongs to: Computer Database Management System (DBMS)
Question #263
Which type of database storage anomaly occurs when adding new data to a table is blocked because other unrelated data is missing?
A. Insertion Anomaly
B. Update Anomaly
C. Modification Anomaly
D. Deletion Anomaly

Correct Answer: Option A


Explanation:
An Insertion Anomaly occurs when certain facts cannot be recorded in a database table without falsely manufacturing or requiring the presence of other unrelated facts.

This question belongs to: Computer Database Management System (DBMS)
Question #264
What type of anomaly occurs when deleting a row inadvertently destroys other independent, valuable historical facts from the database?
A. Projection Anomaly
B. Deletion Anomaly
C. Insertion Anomaly
D. Selection Anomaly

Correct Answer: Option B


Explanation:
A Deletion Anomaly occurs when the deletion of a specific data record unintentionally deletes other distinct, unrelated information that should have been preserved.

This question belongs to: Computer Database Management System (DBMS)
Question #265
Which database anomaly describes the necessity to update the exact same data value in multiple independent rows, creating a risk of data inconsistency?
A. Insertion Anomaly
B. Update Anomaly
C. Structural Anomaly
D. Selection Anomaly

Correct Answer: Option B


Explanation:
An Update Anomaly occurs when data is redundantly duplicated across rows, requiring changes to be made to every copy, risking inconsistencies if any row is missed.

This question belongs to: Computer Database Management System (DBMS)
Question #266
Which clause is used to assign a temporary alias name to a column or table in an SQL statement for better readability?
A. AS
B. WITH
C. LIKE
D. USING

Correct Answer: Option A


Explanation:
The AS keyword is used to assign a temporary alias name to an expression, column, or table within an SQL statement query execution context.

This question belongs to: Computer Database Management System (DBMS)
Question #267
What kind of lock allows multiple concurrent transactions to read a database row simultaneously but blocks any transaction from writing to it?
A. Deadlock
B. Intent Lock
C. Exclusive Lock
D. Shared Lock

Correct Answer: Option D


Explanation:
A Shared Lock (S-lock) permits concurrent transactions to read a resource but prevents any modification operations until the lock is released.

This question belongs to: Computer Database Management System (DBMS)
Question #268
Which type of lock prevents other concurrent transactions from obtaining any form of lock on the same row, securing exclusive read and write access?
A. Exclusive Lock
B. Implicit Lock
C. Shared Lock
D. Static Lock

Correct Answer: Option A


Explanation:
An Exclusive Lock (X-lock) blocks all other locks, ensuring that only the transaction holding the lock can modify or read the protected resource.

This question belongs to: Computer Database Management System (DBMS)
Question #269
What is the situation called when two or more transactions are permanently blocked, each waiting for a lock held by the other transaction to be released?
A. Starvation
B. Concurrency
C. Deadlock
D. Isolation failure

Correct Answer: Option C


Explanation:
A Deadlock occurs when two or more transactions are stuck in a circular dependency, each waiting for resources locked by the other, preventing progress.

This question belongs to: Computer Database Management System (DBMS)
Question #270
Which operator in SQL is used to exclude specific data records from a search based on a collection of negative criteria?
A. EXCEPT
B. MINUS
C. NOT IN
D. REMOVE

Correct Answer: Option C


Explanation:
The NOT IN operator filters the query results to exclude records whose values match any element within the provided list or subquery.

This question belongs to: Computer Database Management System (DBMS)
Question #271
Which data model uses objects, classes, and inheritance features, mirroring concepts from object-oriented programming?
A. Flat Data Model
B. Object-Oriented Data Model
C. Relational Data Model
D. Network Data Model

Correct Answer: Option B


Explanation:
The Object-Oriented Data Model integrates object-oriented programming languages directly with databases, storing data as objects with attributes and methods.

This question belongs to: Computer Database Management System (DBMS)
Question #272
Which SQL component is used to specify a fallback default value for a column when no value is provided during an insert operation?
A. UNIQUE
B. NOT NULL
C. DEFAULT
D. CHECK

Correct Answer: Option C


Explanation:
The DEFAULT constraint assigns a predefined default value to a column when an INSERT statement does not explicitly provide a value for that column.

This question belongs to: Computer Database Management System (DBMS)
Question #273
Which of the following describes an 'Entity' in database terms?
A. A real-world object or concept that is distinguishable from other objects and about which data is stored.
B. A physical server rack.
C. An action or method inside code.
D. A line connecting tables.

Correct Answer: Option A


Explanation:
An Entity is a distinguishable real-world object, place, person, or concept captured within a database schema (e.g., Customer, Product).

This question belongs to: Computer Database Management System (DBMS)
Question #274
What is a 'foreign key' constraint specifically designed to prevent?
A. The use of duplicate data values within the primary key column.
B. Actions that would destroy links or introduce invalid references between tables.
C. Unauthorized login attempts to the database.
D. Slow search execution times.

Correct Answer: Option B


Explanation:
A Foreign Key constraint enforces referential integrity, preventing updates or deletions that would leave orphaned child records pointing to non-existent parent rows.

This question belongs to: Computer Database Management System (DBMS)
Question #275
Which of the following commands is a Data Manipulation Language (DML) statement?
A. COMMENT
B. TRUNCATE
C. RENAME
D. UPDATE

Correct Answer: Option D


Explanation:
UPDATE is a DML statement because it is used to modify existing data values within rows of a database table, rather than modifying the structural schema.

This question belongs to: Computer Database Management System (DBMS)
Question #276
Which statement about primary keys in a relational database table is completely true?
A. Primary keys must always be numeric integers.
B. A table can contain at most one primary key.
C. A primary key column can accept a single NULL value.
D. A table can have multiple distinct primary keys.

Correct Answer: Option B


Explanation:
A relational database table can have exactly one primary key constraint defined, which uniquely identifies each record and strictly forbids NULLs.

This question belongs to: Computer Database Management System (DBMS)
Question #277
What type of join returns all rows from the right table, paired with matching records from the left table, or filling in NULL values if no match is found?
A. Left Outer Join
B. Full Join
C. Right Outer Join
D. Inner Join

Correct Answer: Option C


Explanation:
A Right Outer Join retains all rows from the right table, pairing them with matching left table entries or supplying NULL values if matches do not exist.

This question belongs to: Computer Database Management System (DBMS)
Question #278
Which SQL statement is used to delete an existing view from the database catalog?
A. CLEAR VIEW
B. REMOVE VIEW
C. DROP VIEW
D. DELETE VIEW

Correct Answer: Option C


Explanation:
Because a View is a database structural object, it is removed from the database schema using the DDL command 'DROP VIEW'.

This question belongs to: Computer Database Management System (DBMS)