Database Management System MCQs with Answers
Practice important Database Management System MCQs with answers and explanations.
Multiple Choice Questions
Q411: In the command CREATE TABLE, what does PRIMARY KEY do?
- A: Ensures all values are unique
- B: Allows null values
- C: Forces the use of a default value
- D: Limits the column to numeric values
View Answer
A
Q412: What is the difference between FLOAT and REAL data types in SQL Server?
- A: No difference
- B: REAL is faster than FLOAT
- C: FLOAT allows more precision
- D: REAL allows more precision
View Answer
C
Q413: Which SQL command is used to define the security and authorization information for a database?
- A: DML
- B: DCL
- C: DDL
- D: TCL
View Answer
C
Q414: Which of the following is a valid data type for storing phone numbers in SQL?
- A: TEXT
- B: CHAR(10)
- C: TINYINT
- D: INTEGER
View Answer
B
Q415: What is the output of this SQL statement? CREATE DATABASE School
- A: It creates a new table named "School"
- B: It creates a new database named "School"
- C: It deletes the database "School"
- D: It updates the database "School"
View Answer
B
Q416: What does the constraint CHECK do in SQL?
- A: Ensures that all entries in a column are unique
- B: Enforces rules on the values in a column
- C: Prevents NULL values
- D: Sets a default value
View Answer
B
Q417: Which data type in SQL Server can store whole numbers from -2^31 to 2^31-1?
- A: BIGINT
- B: SMALLINT
- C: TINYINT
- D: INT
View Answer
D
Q418: Fill in the blank: The command to create a new table in SQL starts with ______.
- A: CREATE DATABASE
- B: CREATE TABLE
- C: INSERT INTO
- D: CREATE INDEX
View Answer
B
Q419: Fill in the blank: The constraint that defines a column as the primary identifier of a table is called ______.
- A: FOREIGN KEY
- B: PRIMARY KEY
- C: UNIQUE
- D: CHECK
View Answer
B
Q420: Fill in the blank: A SQL command enclosed in curly braces {} means the part is ______.
- A: Optional
- B: Required
- C: Choice
- D: Default
View Answer
B