Google News
logo
SQL - Quiz(MCQ)
1 .
A view is which of the following?
A)
A virtual table that can be accessed via SQL commands
B)
A virtual table that cannot be accessed via SQL commands
C)
A base table that cannot be accessed via SQL commands
D)
A base table that can be accessed via SQL commands

Correct Answer : Option (A) :   A virtual table that can be accessed via SQL commands

2 .
The SQL keyword(s) ________ is used with wildcards.
A)
IN only
B)
LIKE only
C)
NOT IN only
D)
IN and NOT IN

Correct Answer : Option (B) :   LIKE only

3 .
Which of the following is one of the basic approaches for joining tables?
A)
Subqueries
B)
Union Join
C)
Natural join
D)
All of the above

Correct Answer : Option (D) :   All of the above

4 .
Which of the following statements is true concerning subqueries?
A)
Involves the use of an inner and outer query.
B)
Does not start with the word SELECT.
C)
Cannot return the same result as a query that is not a subquery.
D)
All of the above.

Correct Answer : Option (A) :   Involves the use of an inner and outer query.

5 .
The command to eliminate a table from a database is:
A)
REMOVE TABLE CUSTOMER;
B)
DROP TABLE CUSTOMER;
C)
DELETE TABLE CUSTOMER;
D)
UPDATE TABLE CUSTOMER;

Correct Answer : Option (B) :   DROP TABLE CUSTOMER;

6 .
Which of the following is the correct order of keywords for SQL SELECT statements?
A)
SELECT, FROM, WHERE
B)
FROM, WHERE, SELECT
C)
WHERE, FROM,SELECT
D)
SELECT,WHERE,FROM

Correct Answer : Option (A) :   SELECT, FROM, WHERE

7 .
Which of the following is a correlated subquery?
A)
Uses the result of an inner query to determine the processing of an outer query.
B)
Uses the result of an outer query to determine the processing of an inner query.
C)
Uses the result of an inner query to determine the processing of an inner query.
D)
Uses the result of an outer query to determine the processing of an outer query.

Correct Answer : Option (B) :   Uses the result of an outer query to determine the processing of an inner query.

8 .
ON UPDATE CASCADE ensures which of the following?
A)
Normalization
B)
Data Integrity
C)
Materialized Views
D)
All of the above.

Correct Answer : Option (B) :   Data Integrity

9 .
A subquery in an SQL SELECT statement is enclosed in:
A)
braces -- {...}.
B)
parenthesis -- (...) .
C)
brackets -- [...].
D)
CAPITAL LETTERS.

Correct Answer : Option (B) :   parenthesis -- (...) .

10 .
SQL data definition commands make up a(n) ________ .
A)
DDL
B)
DML
C)
HTML
D)
XML

Correct Answer : Option (A) :   DDL