AQA A2 Computing 5.2 Database Design Flashcards

1
Q

Relation

A

Aset of attributes and tuples, modelling an entity (a table)

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

Attribute

A

A property or characteristic of an entity (a named column in a table)

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

Tuple

A

A set of attribute values (a row in a table)

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

Primary Key

A

An attribute which uniquely identifies a tuple

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

Relational Database

A

A collection of tables

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

Composite Key

A

A combination of attributes that uniquely idetify a tuple

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

Foreign key

A

An attribute in one table that is a primary key in another table(used to form a link between tables)

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

Referential integrity

A

If a value appears in a foreign key in one table, it must also appear in the primary key in another table

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

Normalised entities

A

a set of entities that contain no redundant data

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

Normalisation

A

A technique used to produce a normalised set of entries

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

1NF

A

Atomic data test
A relation is in 1NF if it contains no repeating groups
To convert an unnormalised relation to 1NF either:
Flatten the table and change the primary key, or
Decompose the relation into smaller relations, one for the repeating groups and one for the non-repeating groups.
Remember to put the primary key from the original relation into both new relations.
This option is liable to give the best results.

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

Atomic data test

A

The table does not contain repeating groups of attributes

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

2NF

A

Partial key dependance test
A relation is in 2NF if it contains no repeating groups and no partial key functional dependencies
Rule: A relation in 1NF with a single key field must be in 2NF
To convert a relation with partial functional dependencies to 2NF. create a set of new relations:
One relation for the attributes that are fully dependent upon the key.
One relation for each part of the key that has partially dependent attributes

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

Partial Key dependance test

A

The data is wholly reliant on the primary key.
E.g. an order table which contains customer address would fail as the address is not dependant on the order number. This should be resolved by creating a customer table and linking the order with the customer number

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

3NF

A

Non-Key dependance test
A relation is in 3NF if it contains no repeating groups, no partial functional dependencies, and no transitive functional dependencies
To convert a relation with transitive functional dependencies to 3NF, remove the attributes involved in the transitive dependency and put them in a new relation
Rule: A relation in 2NF with only one non-key attribute must be in 3NF
In a normalised relation a non-key field must provide a fact about the key, the whole key and nothing but the key.
Relations in 3NF are sufficient for most practical database design problems. However, 3NF does not guarantee that all anomalies have been removed.

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