Database (DBMS) Quiz 2

Test your knowledge of database management systems including SQL commands, ACID properties, transactions, JDBC connectivity, and DDL statements.

10 Questions Published

Questions

Question 1 Multiple Choice (Single Answer)

You are managing the in-house database systems.You need to ensure that the user AMY can execute all operations against the SALES relation. What SQL statement sequence will you use?

  1. GRANT ALL PRIVILEGES WHERE FROM ON TO
  2. GRANT ALL PRIVILEGES TO WHERE FROM
  3. GRANT ALL PRIVILEGES WHERE FROM TO
  4. GRANT ALL PRIVILEGES ON TO
  5. GRANT ALL PRIVILEGES ON WHERE FROM
Question 2 Multiple Choice (Single Answer)

You run a SELECT statement, and multiple duplicates of values are retrieved. What keyword can you use to retrieve only the non duplicate data?

  1. DUBPLICATE
  2. INDIVIDUAL
  3. SEPARATE
  4. DISTINCT
  5. INDEX
Question 3 Multiple Choice (Single Answer)

Which of the following elements are the valid components of ACID in a relational database transaction?

  1. Atomicity
  2. Consistency
  3. Isolation
  4. Durability
  5. All of the above
Question 4 Multiple Choice (Single Answer)

In JDBC, what represents a single instance of a particular database session?

  1. a thread
  2. an opened connection
  3. a closed connection
  4. a pipe
Question 5 Multiple Choice (Single Answer)

What statement do you use to remove a schema and its related objects from your relational database?

  1. DROP SCHEMA CASCADE
  2. DROP SCHEMA RESTRICT
  3. DROP SCHEMA ALL
  4. DROP SCHEMA CLEAR
  5. DROP SCHEMA OPTS
Question 6 Multiple Choice (Single Answer)

In a properly designed DBMS, concurrency control is provided by which of the following components.

  1. Process Manager
  2. Cache Manager
  3. Transaction Manager
  4. Lock Manager
  5. C&D
Question 7 Multiple Choice (Single Answer)

Which of the following are valid CREATE statements in the world of DDL?

  1. CREATE SCHEMA
  2. CREATE TABLE
  3. CREATE DOMAIN
  4. CREATE INDEX
  5. All of the above
Question 8 Multiple Choice (Single Answer)

What statement do you use to remove a schema and ensure that the removal takes place only if the schema is empty?

  1. DROP SCHEMA RESTRICT
  2. DROP SCHEMA OPTS
  3. DROP SCHEMA CASCADE
  4. DROP SCHEMA CLEAR
Question 9 Multiple Choice (Single Answer)

What is used by a properly designed DBMS to enable databases to be returned to the pre-transaction state should errors occur?

  1. two phase commit
  2. prefetch transaction
  3. one phase commit
  4. backup and restore
  5. All of the above
Question 10 Multiple Choice (Single Answer)

Under JDBC, which of the following types of instances can be created by the Connection object?

  1. PreparedStatement
  2. CallableStatement
  3. Statement
  4. SQLStatement
  5. AB&C