10 DBMS MCQ Questions and Answer

  1. Which of the following column properties would be used to specify that cells in a column must be immediately filled with a monetary value of $10,000?
    A.Null status
    B.Data type
    C.Default value
    D.Data constraints

Answer: Option C

  1. 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.

Answer: Option B

  1. SQL*Plus will finish the statement and execute it when the user types in this:
    A.A left slash ( ) followed by [Enter].
    B.A colon (: ) followed by [Enter].
    C.A semicolon (;) followed by [Enter].
    D.A period (.) followed by [Enter].

Answer: Option C

4.What will be the outcome of the query that follows?
SELECT first_name, last_name, min(salary)
FROM employees
GROUP BY department_id
HAVING MIN(salary) >
(SELECT min(salary)
FROM employees
WHERE department_id = 100);
A.It executes successfully and gives the names and minimum salary greater than department 100 of all employees
B.It executes successfully and gives the salaries of the employees in department 100
C.It executes successfully and gives the names and minimum salaries of all the employees.
D.It throws an error.

Answer: A.

5………….. joins two or more tables based on a specified column value not equaling a specified column value in another table.
A.EQUIJOIN
B.NON-EQUIJOIN
C.OUTER JOIN
D.NATURAL JOIN

Answer: Option B

6.You need to find the salaries for all the employees who have a higher salary than the Vice President of a company ‘ABC’.Which of the following queries will give you the required result? (Consider the table structure as given)
SQL> DESC employees
Name Null? Type


EMPLOYEE_ID NOT NULL NUMBER(6)
FIRST_NAME VARCHAR2(20)
LAST_NAME NOT NULL VARCHAR2(25)
EMAIL NOT NULL VARCHAR2(25)
PHONE_NUMBER VARCHAR2(20)
HIRE_DATE NOT NULL DATE
JOB_ID NOT NULL VARCHAR2(10)
SALARY NUMBER(8,2)
COMMISSION_PCT NUMBER(2,2)
MANAGER_ID NUMBER(6)
DEPARTMENT_ID NUMBER(4)

(a)
SELECT first_name, last_name, salary
FROM employees
WHERE salary > (SELECT salary
FROM employees
WHERE job_id = ‘VICE-PRESIDENT’);
(b)
SELECT first_name, last_name, salary
FROM employees
WHERE salary = (SELECT salary
FROM employees
WHERE job_id = ‘VICE-PRESIDENT’);
(c)
SELECT first_name, last_name, salary
FROM employees
WHERE job_id = ‘VICE-PRESIDENT’);
D. None of the above

Answer: A.

  1. The index which has an entry for some of the key value is classified as
    A. linear index
    B. dense index
    C. non dense index
    D. cluster index

Answer-c

  1. The primary indexes, secondary indexes and cluster indexes are all types of
    A.ordered indexes
    B.unordered indexes
    C.linear indexes
    D.relative search indexes

Answer-A

  1. In multilevel indexes, the primary index created for its first level is classified as
    A.zero level of multilevel index
    B.third level of multilevel index
    C.second level of multilevel index
    D.first level of multilevel index

Answer-C

  1. The indexes which specifies address of records on disk with a physical pointer are classified as
    A.structural index
    B.hashing index
    C.physical index
    D.logical index

Answer-C

Leave a Comment