Databases & DBMS MCQs

20 practice MCQs on this page Page 13 of 16

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

Computer ScienceDatabases & DBMS PPSCID: LTP-8795

What is an entity in a database?

  1. AA type of virus
  2. BA database password
  3. CA backup file
  4. DA real-world object about which data is stored ✓ Correct answer
Computer ScienceDatabases & DBMS PPSCID: LTP-8796

What is an attribute in a database?

  1. AA property or characteristic of an entity ✓ Correct answer
  2. BA type of table
  3. CA database user
  4. DA backup copy
Computer ScienceDatabases & DBMS PPSCID: LTP-8797

Which SQL clause filters rows in a query?

  1. AORDER BY
  2. BWHERE ✓ Correct answer
  3. CGROUP BY
  4. DHAVING
Computer ScienceDatabases & DBMS PPSCID: LTP-8799

Which type of JOIN returns only rows that match in both tables?

  1. ALEFT JOIN
  2. BRIGHT JOIN
  3. CFULL JOIN
  4. DINNER JOIN ✓ Correct answer
Computer ScienceDatabases & DBMS PPSCID: LTP-8800

Which type of JOIN returns all rows from the left table even if there is no match?

  1. ALEFT JOIN ✓ Correct answer
  2. BINNER JOIN
  3. CRIGHT JOIN
  4. DCROSS JOIN
Computer ScienceDatabases & DBMS PPSCID: LTP-8801

What does ACID stand for in database transactions?

  1. AAccuracy, Consistency, Integrity, Durability
  2. BAtomicity, Consistency, Isolation, Durability ✓ Correct answer
  3. CAtomicity, Control, Isolation, Data
  4. DAccess, Consistency, Index, Durability
Computer ScienceDatabases & DBMS PPSCID: LTP-8802

What is a transaction in a database?

  1. AA report printed from a database
  2. BA backup of a table
  3. CA single unit of work that must complete fully or not at all ✓ Correct answer
  4. DA user login to a database
Computer ScienceDatabases & DBMS PPSCID: LTP-8803

What is an index in a database?

  1. AA list of all database users
  2. BA copy of a table
  3. CA type of primary key
  4. DA structure that speeds up finding rows in a table ✓ Correct answer
Computer ScienceDatabases & DBMS PPSCID: LTP-8804

Which SQL command removes all rows from a table but keeps its structure?

  1. ATRUNCATE TABLE ✓ Correct answer
  2. BDELETE TABLE
  3. CDROP TABLE
  4. DCLEAR TABLE
Computer ScienceDatabases & DBMS PPSCID: LTP-8893

Which key in a database table uniquely identifies each row and cannot contain a duplicate or empty value?

  1. AForeign key
  2. BPrimary key ✓ Correct answer
  3. CCandidate key
  4. DAlternate key
Computer ScienceDatabases & DBMS PPSCID: LTP-8894

The standard language used to create, read, update and delete data in a relational database is called what?

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

Which normal form requires that every non-key attribute depends on the whole primary key and on nothing but the key?

  1. AFirst normal form
  2. BThird normal form ✓ Correct answer
  3. CUnnormalised form
  4. DDenormalised form
Computer ScienceDatabases & DBMS PPSCID: LTP-8899

In a database management system, the software component that manages the stored data and lets users query it is called the what?

  1. AWord processor
  2. BSpreadsheet
  3. CWeb server
  4. DDatabase engine ✓ Correct answer
Computer ScienceDatabases & DBMS PPSCID: LTP-8901

A database view is best described as what?

  1. AA printed report of the data
  2. BA virtual table based on a query over real tables ✓ Correct answer
  3. CA backup copy of the whole database
  4. DA physical disk partition
Computer ScienceDatabases & DBMS BPSCID: BPP-4042

In a database, a table is made up of:

  1. ARows and columns ✓ Correct answer
  2. BPages and lines
  3. CFiles and folders
  4. DSheets and cells
Computer ScienceDatabases & DBMSID: DB-001

In a hierarchical database model, data is organised in the form of:

  1. ATables of rows and columns
  2. BDocuments in collections
  3. CA tree structure with parent-child links ✓ Correct answer
  4. DA graph of nodes and edges
Computer ScienceDatabases & DBMSID: DB-002

In the network database model, a record can have:

  1. AOnly one parent record
  2. BNo relationships at all
  3. CMore than one parent record ✓ Correct answer
  4. DOnly a primary key
Computer ScienceDatabases & DBMSID: DB-003

In the three-schema architecture of a database, the conceptual schema describes:

  1. AHow data is stored on disk
  2. BWhat one user sees of the database
  3. CThe logical structure of the whole database ✓ Correct answer
  4. DThe physical files of the database
Computer ScienceDatabases & DBMSID: DB-004

Physical data independence means that:

  1. AUsers can change the conceptual schema freely
  2. BThe database needs no backup
  3. CThe physical storage can change without changing the logical structure ✓ Correct answer
  4. DEvery user sees the same view
Computer ScienceDatabases & DBMSID: DB-005

In an ER diagram, an entity is represented by a:

  1. ADiamond
  2. BEllipse
  3. CRectangle ✓ Correct answer
  4. DDouble ellipse

Practice these MCQs interactively