Computer Science for IGCSE & O level - Databases (Section 3)

1
What is data integrity?
Answer
(B)
The accuracy and consistency of the data.
2
Which data type is typically used to store whole numbers?
Answer
(B)
INTEGER
3
Which of the following are common database data types?
Answer
A
B
C
4
Which SQL command is used to retrieve specific data from a database table?
Answer
(C)
SELECT
5
Which SQL statement is used to delete data from a database table?
Answer
(C)
DELETE
6
What are the potential problems associated with data redundancy?
Answer
A
B
D
7
Which of the following best describes the 'normalization' process in databases?
Answer
(C)
Organizing data to reduce redundancy and improve data integrity.
8
Which statement is correct regarding the number of tables in a single-table database in this context?
Answer
(B)
It contains only one table.
9
Which of the following is true about primary keys?
Answer
B
C
10
Which of the following is an example of a data type used in databases?
Answer
(C)
Integer
11
Which command is used to create a database?
Answer
(A)
CREATE DATABASE
12
What is the purpose of the 'UNIQUE' constraint in a database?
Answer
(B)
To prevent duplicate values in a column.
13
Which SQL command is used to insert new data into a table?
Answer
(C)
INSERT
14
What is the purpose of a database backup?
Answer
(B)
To recover data in case of loss or corruption.
15
Which of the following is a benefit of using a database over a simple file system for storing data?
Answer
B
C
16
Which of the following is a key goal of database security?
Answer
B
C
17
Which of the following are typical characteristics of a good primary key?
Answer
A
B
C
18
What is the role of the `SELECT` statement in SQL?
Answer
(C)
To retrieve data.
19
What does the term 'schema' refer to in a database context?
Answer
(B)
The structure of the database, including tables, columns, and relationships.
20
What does the 'NOT NULL' constraint ensure in a database?
Answer
(C)
That a field must have a value.
21
What does ACID properties refer to in the context of database transactions?
Answer
(B)
Atomicity, Consistency, Isolation, Durability
22
Which SQL command is used to retrieve data from a database?
Answer
(C)
SELECT
23
Which SQL clause is used to sort the results of a query?
Answer
(C)
ORDER BY
24
In the context of SQL, what does the term 'JOIN' refer to?
Answer
(B)
A way to combine data from multiple tables based on a related column.
25
Which of the following is an example of an aggregate function in SQL?
Answer
(B)
`COUNT`
26
What is the purpose of a 'constraint' in a database?
Answer
(B)
To enforce rules and restrictions on data.
27
Which of the following is NOT a characteristic of a single-table database?
Answer
(C)
Can be used to store complex data.
28
What are the advantages of using a relational database over flat files?
Answer
(D)
All of the above.
29
What is the purpose of a WHERE clause in an SQL query?
Answer
(C)
To filter the data based on specified conditions.
30
Which of the following are examples of database management software?
Answer
A
B
D
31
Which SQL commands are used to modify the data in the database?
Answer
A
B
C
32
What do we mean by 'data dictionary' in context of database?
Answer
(C)
A collection of metadata about the database's structure.
33
Which of the following is an example of a DML command?
Answer
B
C
34
What is the function of the `ALTER TABLE` statement in SQL?
Answer
(C)
To modify the structure of an existing table.
35
Which data type is best suited for storing currency values (e.g., money amounts) in a database?
Answer
(C)
DECIMAL or NUMERIC
36
Which of the following are essential components in database design?
Answer
A
B
C
37
Which SQL statement is used to retrieve data from a database?
Answer
(C)
SELECT
38
What is the main function of a database?
Answer
(B)
To store and organize data
39
What is the function of an aggregate function in SQL (e.g., `SUM`, `AVG`)?
Answer
(B)
To perform calculations on a set of values.
40
What does the term 'database integrity' mean?
Answer
(B)
The accuracy, consistency, and reliability of data.
41
What does the 'ALTER TABLE' command do in SQL?
Answer
(B)
Modifies the structure of an existing table.
42
Which of the following is an example of a suitable primary key for a student table?
Answer
(C)
Student ID
43
Which SQL statement is used to modify existing data in a database table?
Answer
(C)
UPDATE
44
What is the purpose of a 'trigger' in a database?
Answer
(B)
To automatically execute a set of actions in response to an event.
45
Which of the following is a task that is typically performed during database design?
Answer
(C)
Defining the data types for each field.
46
What are some examples of the benefits of SQL?
Answer
A
B
C
D
47
What are the benefits of using SQL in a database?
Answer
A
C
48
What are some common validation checks that can be applied to data in a database?
Answer
A
B
C
D
49
Which of the following is a key characteristic of a relational database?
Answer
(B)
Data is organized into tables with rows and columns.
50
Which SQL keyword is used to group rows that have the same values in one or more columns into a summary row?
Answer
(C)
GROUP BY