• Practice
  • 15 practice questions

Final self-assessment: database basics

Test yourself on the whole course: 15 questions with answers explained.

If something looks wrong, please tell us.

Attempt all 15 questions before checking any answer; they are a little harder than the lesson checks. Then revisit the lesson for any question you missed - questions 1-3: lesson 1, Tables, records, fields and DBMS; questions 4-6: lesson 2, Keys and relationships between tables; questions 7-9: lesson 3, SQL basics: SELECT, WHERE and common commands; questions 10-12: lesson 4, Data integrity, redundancy and normalisation; questions 13-15: lesson 5, Database mixed practice.

Final self-assessment

  1. 1. A table has 30 records and 7 fields. Two records are deleted. How many data cells remain?

    1. 210
    2. 196
    3. 203
    4. 182
    Show answer

    Answer: B. 28 records remain: 28 x 7 = 196.

  2. 2. Which pair is matched correctly?

    1. Record: one column; field: one row
    2. Table: one cell; field: one table
    3. Record: one row; field: one column
    4. Primary key: a field whose values may repeat
    Show answer

    Answer: C. A row is a record and a column is a field; a primary key never repeats.

  3. 3. A student table has the fields Roll number, Name, City and Class. Which pair of fields can BOTH hold repeated values, so neither can be the primary key?

    1. Roll number and Name
    2. Roll number and City
    3. Roll number and Class
    4. Name and City
    Show answer

    Answer: D. Two students can share a name or a city. Every pair with Roll number includes a unique field.

  4. 4. Tables DEPARTMENT(DeptID, DeptName) and EMPLOYEE(EmpID, Name, DeptID). Which statement is correct?

    1. DeptID is the primary key of DEPARTMENT and a foreign key in EMPLOYEE
    2. DeptID is the primary key of EMPLOYEE
    3. EmpID is a foreign key in DEPARTMENT
    4. Name is the primary key of both tables
    Show answer

    Answer: A. DeptID identifies departments; in EMPLOYEE it points back to DEPARTMENT, so it is a foreign key there. EMPLOYEE's primary key is EmpID.

  5. 5. A MARKS table holds one row per student per subject, so neither RollNo nor SubjectCode is unique on its own. What should the primary key be?

    1. RollNo alone
    2. RollNo and SubjectCode together, as a composite key
    3. SubjectCode alone
    4. The marks column
    Show answer

    Answer: B. Together the pair is unique for each row, so it forms a composite primary key.

  6. 6. Each student takes many subjects and each subject has many students. The relationship is

    1. One-to-one
    2. One-to-many
    3. Many-to-many
    4. Many-to-one
    Show answer

    Answer: C. Many records on each side match many on the other.

  7. 7. Student table marks: Asha 72, Bilal 55, Chitra 90, Dev 60. What does SELECT COUNT(*) FROM Student WHERE Marks > 60; return?

    1. 3
    2. 4
    3. 1
    4. 2
    Show answer

    Answer: D. Only 72 and 90 are greater than 60. Dev's 60 is not, which is the common trap.

  8. 8. Student table marks: Asha 72, Bilal 55, Chitra 90, Dev 60. What does SELECT SUM(Marks) FROM Student WHERE Marks < 72; return?

    1. 115
    2. 187
    3. 60
    4. 277
    Show answer

    Answer: A. Marks below 72 are 55 and 60: 55 + 60 = 115. Asha's 72 is not less than 72.

  9. 9. In SELECT Name FROM Student WHERE Marks > 60; which part names the table?

    1. SELECT Name
    2. FROM Student
    3. WHERE Marks > 60
    4. Name
    Show answer

    Answer: B. SELECT chooses the column, FROM names the table and WHERE filters the rows.

  10. 10. A student's address is stored in ten rows. It changes and only nine rows are updated. What is the result?

    1. The data becomes normalised
    2. A data dictionary is created
    3. The data becomes inconsistent
    4. Data integrity improves
    Show answer

    Answer: C. One row still has the old address, so the copies disagree: inconsistency caused by redundancy.

  11. 11. How does a normalised design avoid the problems of an address repeated in many rows?

    1. Copy the address into even more rows
    2. Delete the address field completely
    3. Take a backup every day
    4. Store the address once in a separate table and link it with a key
    Show answer

    Answer: D. Storing it once means one update corrects it everywhere.

  12. 12. Which statement is correct?

    1. Normalisation reduces redundancy, and integrity keeps data correct and consistent
    2. Normalisation increases redundancy to make searches faster
    3. Integrity means deleting old data
    4. A backup removes redundancy
    Show answer

    Answer: A. Normalisation organises tables to reduce repetition; integrity rules keep data valid.

  13. 13. Item table prices: 40, 25, 60, 75. What does SELECT COUNT(*) FROM Item WHERE Price > 40; return?

    1. 3
    2. 2
    3. 1
    4. 4
    Show answer

    Answer: B. Only 60 and 75 are greater than 40; 40 itself is not.

  14. 14. Item table prices: 40, 25, 60, 75. What does SELECT SUM(Price) FROM Item WHERE Price >= 60; return?

    1. 175
    2. 60
    3. 135
    4. 200
    Show answer

    Answer: C. Prices of at least 60 are 60 and 75: 60 + 75 = 135.

  15. 15. Which cue is matched to the right term?

    1. Retrieve data: INSERT
    2. Unique identifier: foreign key
    3. Reduce repeated data: redundancy
    4. Points to another table: foreign key
    Show answer

    Answer: D. A foreign key points to another table's primary key. SELECT retrieves, the primary key is the unique identifier, and normalisation reduces repeated data.

Privacy · Terms · Refunds · Delivery