Database Flashcards

(24 cards)

1
Q

What is a data model?

A

An abstract model of which things to store and what information about them should be recorded

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

Define an entity in the context of a database

A

A thing about which data is to be stored

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

What are attributes in a database?

A

Characteristics or other information about entities

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

How are databases structured?

A

Databases are formed of tables which are used to store multiple entities

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

What does each row in a database table typically represent?

A

Each entity

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

What is an entity identifier?

A

An attribute given to each entity which is unique within that table

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

How can multiple attributes form an entity identifier?

A

Some database tables have multiple attributes which are combined to form the table’s entity identifier

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

What is the purpose of an entity description?

A

To describe how information is to be stored about entities

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

What is a primary key?

A

An attribute that provides a unique identifier for every entity in a database table

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

What is a foreign key?

A

An attribute in a table which is the primary key in another, related table

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

What is a link table?

A

A new table created when linking many-to-many relationships

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

What is database normalization?

A

The process of organizing a database to minimize redundancy and improve data integrity

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

What is the main goal of normalizing databases?

A

To ensure that entities contain no redundant or repeated data

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

What are the advantages of a normalized database?

A

Faster searching and sorting, easier maintenance, minimized duplication, improved data consistency

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

What characterizes a database in first normal form?

A

Must not contain any repeating attributes and has atomic data

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

Define second normal form in databases

A

Must satisfy first normal form and have any partial key dependencies removed

17
Q

What is a partial key dependency?

A

Occurs when a non-key attribute doesn’t depend on the whole of the composite key

18
Q

What conditions must a database meet to be in third normal form?

A

Must conform to second normal form and have no non-key dependencies

19
Q

What does it mean when non-key attributes depend on the key?

A

All non-key attributes depend on the key, the whole key, and nothing but the key

20
Q

What are the three possible degrees of relationship between tables in a database?

A
  • one-to-one
  • one-to-many
  • many-to-many
21
Q

Describe a one-to-one relationship with an example

A

Each car has one owner, and each owner has one car

22
Q

Describe a one-to-many relationship with an example

A

Each driver can drive many different cars. Each car is driven by many different drivers

23
Q

Describe a one to-many relationship with an example

A

Each car has many passengers. Each passenger sits in one car

24
Q

What does an entity relationship diagram represent?

A

Graphically represents the relationships between tables in a database