Databases & DBMS MCQs

20 practice MCQs on this page Page 12 of 16

Tap an option to check your answer — the correct answer and full explanation appear after you choose.

Computer ScienceDatabases & DBMS PPSCID: LTP-8498

Which SQL clause sorts the result of a query?

  1. AWHERE clause
  2. BGROUP BY clause
  3. CORDER BY clause ✓ Correct answer
  4. DJOIN clause
Computer ScienceDatabases & DBMS PPSCID: LTP-8499

Which SQL operation combines rows from two tables using a related column?

  1. AUNION
  2. BGROUP BY
  3. CORDER BY
  4. DJOIN ✓ Correct answer
Computer ScienceDatabases & DBMS PPSCID: LTP-8500

Which key is a minimal set of columns that can uniquely identify a row?

  1. ACandidate key ✓ Correct answer
  2. BForeign key
  3. CPrimary key
  4. DSuper key
Computer ScienceDatabases & DBMS PPSCID: LTP-8501

Which term means the accuracy and consistency of stored data?

  1. AData redundancy
  2. BData integrity ✓ Correct answer
  3. CData independence
  4. DData mining
Computer ScienceDatabases & DBMS PPSCID: LTP-8502

Which database object is a saved set of SQL statements that can be run by name?

  1. AView
  2. BIndex
  3. CStored procedure ✓ Correct answer
  4. DTrigger
Computer ScienceDatabases & DBMS PPSCID: LTP-8504

Which database type stores data in documents or key-value pairs instead of tables?

  1. ANoSQL database ✓ Correct answer
  2. BRelational database
  3. CHierarchical database
  4. DNetwork database
Computer ScienceDatabases & DBMS PPSCID: LTP-8612

Which software is used to create and manage a database?

  1. ADatabase Management System ✓ Correct answer
  2. BWord processor
  3. CWeb browser
  4. DSpreadsheet
Computer ScienceDatabases & DBMS PPSCID: LTP-8613

In SQL, which clause is used to filter groups after GROUP BY?

  1. AWHERE
  2. BHAVING ✓ Correct answer
  3. CORDER BY
  4. DLIMIT
Computer ScienceDatabases & DBMS PPSCID: LTP-8614

What is a primary key?

  1. AA field that links two tables
  2. BA password for a database
  3. CA field that uniquely identifies each record in a table ✓ Correct answer
  4. DThe first column of a table
Computer ScienceDatabases & DBMS PPSCID: LTP-8615

What is a foreign key?

  1. AA key that is no longer used
  2. BA password for a foreign user
  3. CThe last column of a table
  4. DA field that links a table to the primary key of another table ✓ Correct answer
Computer ScienceDatabases & DBMS PPSCID: LTP-8616

What is a candidate key?

  1. AA field or combination of fields that can uniquely identify a record ✓ Correct answer
  2. BA key used by candidates in exams
  3. CA temporary password
  4. DA duplicate of the primary key
Computer ScienceDatabases & DBMS PPSCID: LTP-8618

Which language do you use to ask a database for information?

  1. AHTML
  2. BCSS
  3. CSQL ✓ Correct answer
  4. DJavaScript
Computer ScienceDatabases & DBMS PPSCID: LTP-8619

Which SQL command retrieves data from a table?

  1. AINSERT
  2. BUPDATE
  3. CDELETE
  4. DSELECT ✓ Correct answer
Computer ScienceDatabases & DBMS PPSCID: LTP-8712

Which SQL command adds a new record to a table?

  1. AINSERT ✓ Correct answer
  2. BSELECT
  3. CUPDATE
  4. DDELETE
Computer ScienceDatabases & DBMS PPSCID: LTP-8714

Which SQL command removes a record from a table?

  1. ASELECT
  2. BINSERT
  3. CDELETE ✓ Correct answer
  4. DUPDATE
Computer ScienceDatabases & DBMS PPSCID: LTP-8715

Which SQL command creates a new table?

  1. ASELECT TABLE
  2. BINSERT TABLE
  3. CMAKE TABLE
  4. DCREATE TABLE ✓ Correct answer
Computer ScienceDatabases & DBMS PPSCID: LTP-8716

Which SQL command removes a table completely?

  1. ADROP TABLE ✓ Correct answer
  2. BDELETE TABLE
  3. CREMOVE TABLE
  4. DCLEAR TABLE
Computer ScienceDatabases & DBMS PPSCID: LTP-8717

What is normalisation in a database?

  1. ACompressing a database file
  2. BOrganising data to reduce redundancy and improve integrity ✓ Correct answer
  3. CEncrypting database passwords
  4. DCopying a database to another server
Computer ScienceDatabases & DBMS PPSCID: LTP-8718

Which normal form requires that every column holds only atomic values?

  1. ASecond Normal Form
  2. BThird Normal Form
  3. CFirst Normal Form ✓ Correct answer
  4. DBoyce-Codd Normal Form
Computer ScienceDatabases & DBMS PPSCID: LTP-8719

What is an ER diagram used for?

  1. AShowing the speed of a database
  2. BListing all users of a database
  3. CEncrypting database tables
  4. DShowing entities and their relationships in a database design ✓ Correct answer

Practice these MCQs interactively