Mock Exam Flashcards

1
Q

What does the HAVING clause do?

A

filters the rows (after aggregation)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

What does the SELECT line do?

A

determines which columns appear

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

What does the FROM clause do?

A

determines which tables are searched

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

What does the GROUP BY clause do?

A

determines how aggregate functions are evaluated

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

What does the WHERE clause do?

A

filters the rows (before aggregation)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

What should a composite key index do?

A

It should improve the performance of some SELECT queries.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

Of the following options, which is Database Vendor Dependent:

  1. Physical Design
  2. The Data Dictionary
  3. Logical Design
  4. Normalisation
A

Physical Design

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

What is an important part of a database administrator’s role

A

Ensuring that the database is backed up regularly.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

All tables must have a foreign key - True or False?

A

False

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

Foreign Keys ensure referential integrity - True or False?

A

True

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

What is the term for combining two relations based on values in one attribute in each relation being the same?

A

Equi-Join

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

The label at the “child” end of an optional, one-to-many relationship should be:

A

0..*

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

What is the stage of normalisation at which the following issue is addressed:

Eliminate partial key dependancies:

A

Second Normal Form

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

Select the true statement about the multiplicity label shown:

0..1

Select one:

a. The entity is mandatory. The corresponding foreign key cannot be null.
b. The entity is optional. The corresponding foreign key cannot be null.
c. This is not a valid multiplicity label.
d. The entity is optional. The corresponding foreign key may be null.
e. The entity is mandatory. The corresponding foreign key may be null.

A

The entity is optional. The corresponding foreign key may be null.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

Each table should have exactly one Primary Key - True or False?

A

True

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

What is the term for the maximum number of entities that can participate in a relationship?

A

Cardinality

17
Q

What does ‘Access Control’ allow a user to do?

A

allows user X to insert records into table T

18
Q

What is an appropriate response to an SQL injection attack

A

Inspect program code to ensure that SQL statements cannot be compromised.

19
Q

What part of SQL uses the ‘ON’ condition

A

JOIN

20
Q

What is the mongodb function that corresponds most closely to an SQL SELECT statement with a GROUP BY clause.

A

aggregate

21
Q

What is meant by Scalability in regards to NoSQL

A

NoSQL databases allow many machines to process a single query simultaneously.

22
Q

Relational Databases are so called because…

a. It is important to maintain good relations.
b. The main data structure used is a relation.
c. The database manages relations between entities.
d. Only related data can be stored in these databases.
e. All implementations are related.

A

b. The main data structure used is a relation.

23
Q

Using a transaction log reduces Database Performance - True or False?

A

True

24
Q

Which property of transactions is guaranteed by the two-phase locking strategy?

A

Serialisability

25
Q

What is the term for the conceptual separation of logical data from physically stored data?

A

Data Independence

26
Q

What is the term for a lock taken out by a read-only transaction?

A

Shared