(a) Relational database concepts Flashcards

1
Q

What is a flat file database?

A

A database that only has 1 table

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

What is a relational database?

A

A database with multiple related tables connected through keys

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

What is a primary key?

A

A unique identifier for a record in a table.

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

What is a foreign key?

A

A field in one table that links to the primary key in another table which creates a relationship

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

What is a composite key?

A

A **type of primary key **which uses two or more fields from a table to create a unique value.

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

What is a secondary key?

A

An attribute used to search the database but not always unique.

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

What is an entity in databases?

A

People or things

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

What is entity-relationship modelling (ERM)?

A

A diagram for showing entities and the relationships between them

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

What is a 1:1 relationship in ER modelling?

A

One entity instance relates to one in another (e.g., Person → Passport).

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

What is a 1:M relationship in ER modelling?

A

One entity relates to many others (e.g., Customer → Orders).

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

What is a M:N relationship in ER modelling?

A

Many-to-many; must be broken into two 1:M with a linking table.

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

What is indexing in a database?

A

A technique for speeding up data retrieval, often using B-trees or hash tables.

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