Chapter 4: Logical Database Design and the Relational Model Flashcards

1
Q

The entity relationship diagram is a logical data model (T or F)

A

False

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

What is the objective of logical database design?

A

To transform the conceptual design into a logical database design that can be implemented via a chosen dbms

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

The relational model is based on mathematics (T or F)

A

True

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

What are the 3 components of a relational data model?

A
  1. Data structure
  2. Data manipulation
  3. Data integrity
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

A named two-dimensional table
of data

A

relation

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

is an attribute or a combination of attributes that
uniquely identifies each row in a relation

A

primary key

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

A primary key that consists of
more than one attribute

A

composite key

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

What is used to show relationships with relations?

A

Foreign keys

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

In the shorthand notation, what is used to identify foreign and primary keys?

A

PK: Solid underline
FK: Dashed underline

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

Properties of Relations: What are the properties of relations?

A
  1. Has a unique name
  2. rows and columns are atomic
  3. each row is unique
  4. each column is unique
  5. The sequence of columns are insignificant
  6. the sequence of rows is insignificant
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

a description of the overall logical structure of the database

A

Schema

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

What are the two common methods for expressing a schema

A
  1. short text statements
  2. graphical representation
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

Integrity Constraints: What are the three constraints found in relational data models?

A
  1. Domain Constraint
  2. Entity Integrity
  3. Referential Integrity
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

Integrity Constraints: is the set of values that may be assigned to an attribute

A

Domain Constraint

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

Integrity Constraints: is design to ensure that every relation has a primary key and that the data values are all valid

A

Entity Integrity

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

Integrity Constraints: In entity integrity, it ensures that all primary key attributes are?

A

Non-null

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

Integrity Constraints: A value that may be assigned to an attribute when no other value
applies or when the applicable
value is unknown.

A

Null

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

Integrity Constraints: A rule that states that either each
foreign key value must match
a primary key value in another
relation or the foreign key value
must be null.

A

referential integrity constraint

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

Integrity Constraints: In referential integrity, it is allowed to have a null foreign key if?

A

The relationship is optional

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

Well-Structured Relations: A relation that contains __ ___ and allows users
to __ ___ __ ___the
rows in a table without errors or
inconsistencies.

A
  1. minimal redundancy
  2. insert, modify, and delete
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
21
Q

Well-Structured Relations: Redundancies may lead to?

A

Anomalies

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

Well-Structured Relations: An error or inconsistency that
may result when a user attempts
to update a table that contains
redundant data

A

anomaly

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

Well-Structured Relations: What are the three anomalies?

A
  1. Insertion
  2. Deletion
  3. Modification
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
24
Q

Well-Structured Relations: Restrictions in composite primary keys when creating new tables are what anomaly?

A

Insertion Anomaly

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

Well-Structured Relations: When a removal of an attribute leads to a deletion of the whole instance

A

Deletion Anomaly

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

Well-Structured Relations: When updating needs to be done to every instance is what type of anomaly?

A

Modification Anomaly

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

Transforming EER Diagrams into Relations: aare entities that have an independent existence and generally represent real-world objects, such as persons and products. It is represented by what in a graphical representation?

A

Regular Entities. By a solid line box

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

Transforming EER Diagrams into Relations: are entities that cannot exist except with an identifying relationship with an owner (regular) entity type. It is identified in a graphical representation as?

A

Weak Entities. A double line box

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

Transforming EER Diagrams into Relations: are formed from many-to-many relationships between other entity types. It is identified in a graphical representation with?

A

Associative Entities. Rounded cornered box

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

Transforming EER Diagrams into Relations: Associative entities are also called?

A

Gerunds

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

Transforming EER Diagrams into Relations: What are the steps in creating relational data models?

A
  1. Map Regular Entities
  2. Map Weak Entities
  3. Map Binary Entities
  4. Map Associative Entities
  5. Map Unary Entities
  6. Map Ternary Relationships
  7. Map Supertype/Subtype Relationships
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
32
Q

Transforming EER Diagrams into Relations: What happens to entities in step 1?

A

They become relations/tables

33
Q

Transforming EER Diagrams into Relations: What will you do if there are composite attributes from an entity?

A

Separate each attribute into its own columns

34
Q

Transforming EER Diagrams into Relations: What would you do with multivalued attributes?

A

Create a separate relation for the said attribute, and then use the primary key of the original relation and the ex- multivalued attribute as the primary keys

35
Q

Transforming EER Diagrams into Relations: Nonkey attributes are also called

A

descriptors

36
Q

Transforming EER Diagrams into Relations: exists only
through an identifying relationship with another entity type called the

A

owner

37
Q

Transforming EER Diagrams into Relations: a weak entity has no complete identified and only uses a?

A

partial identifier

38
Q

Transforming EER Diagrams into Relations: What do you do when there is a weak and strong entity relationship in your E-R diagram?

A

The weak entity references the pk of the strong entity and its partial identifier as its primary keys

39
Q

Transforming EER Diagrams into Relations: A serial number or other systemassigned primary key for a relation.

A

Surrogate primary key

40
Q

Transforming EER Diagrams into Relations: What are the instances when you use a surrogate key?

A
  1. When there is a composite primary key
  2. When the natural primary key is inefficient
  3. When it cannot be unique in the future
41
Q

Transforming EER Diagrams into Relations: For binary 1:M, what do you do?

A

Create two relations, wherein the foreign key is placed on the “many” relation

42
Q

Transforming EER Diagrams into Relations: Are foreign keys required to be the same names at the primary key it is referencing?

A

No. As long as it has the same domain.

43
Q

Transforming EER Diagrams into Relations: In binary m:n, how do you do it?

A

Create 3 relations, each having their own unique attributes while the third one uses a composite key of both the original relations. (Associative Entity)

44
Q

Transforming EER Diagrams into Relations: In binary 1:1, what do you do?

A

Create 2 relations, the optional relation has the foreign key reference

45
Q

Transforming EER Diagrams into Relations: When identifiers are not assigned, associative entities use what primary keys?

A

A composite primary key of the two related relations

46
Q

Transforming EER Diagrams into Relations: When an identifier is assigned to an associative entity, how would the relation look like?

A
  1. The primary key will be the assigned one
  2. The primary keys of the other two relations are referenced using foreign keys
47
Q

Transforming EER Diagrams into Relations: In unary 1:M relationships, how would you make it?

A
  1. Create a relation
  2. Add a foreign key that references the primary key of the same relation
48
Q

Transforming EER Diagrams into Relations: A foreign key in a relation that references the primary key values of the same relation

A

recursive foreign key

49
Q

Transforming EER Diagrams into Relations: A unary M:N relationship is made how?

A
  1. Create two relations (one is an associative entity)
  2. A composite key that references the PK of the main relation
50
Q

Transforming EER Diagrams into Relations: In a ternary relationship what is the default primary key?

A

The primary keys of the three relation and partial identifier of the associative entity

51
Q

Normalization: When should you use normalization?

A
  1. During logical database design
  2. When reverse-engineering older systems
52
Q

decomposing relations with anomalies

A

Normalization

53
Q

Normalization: Normalization makes no assumptions about how data will be used in displays (T or F)

A

True

54
Q

Normalization: is based on normal forms or functional dependencies defines data usage (T or F)

A

False. Business Rules dapat

55
Q

Normalization: A state of a relation that requires
that certain rules regarding
relationships between attributes
(or functional dependencies) are
satisfied

A

Normal form

56
Q

Steps in Normalization: What is the rules for first normal form?

A

multivalued attributes have been removed

57
Q

Steps in Normalization: Can intersections in the table be null I the first normal form?

A

Yes

58
Q

Steps in Normalization: rule for 2nd normal form?

A

Remove partial functional dependencies

59
Q

Steps in Normalization: rules for 3rd normal form

A

Transitive dependencies are removed

60
Q

Steps in Normalization: Any remaining anomalies that result from functional dependencies have been removed

A

Boyce Codd normal form

61
Q

Steps in Normalization: Any multivalued dependencies have been removed

A

foruth normal form

62
Q

Steps in Normalization: Any remaining anomalies have been removed

A

Fifth normal form

63
Q

Normalization:A constraint between two
attributes in which the value of
one attribute is determined by the
value of another attribute.

A

Functional dependency

64
Q

Normalization:The attribute on the left side of the
arrow in a functional dependency

A

Determinant

65
Q

Normalization:An attribute, or combination of
attributes, that uniquely identifies
a row in a relation

A

Candidate key

66
Q

Normalization:What are the two properties of Candidate Keys?

A
  1. Unique
  2. Nonredundant
67
Q

Normalization:Are all candidate keys determinants? What about the other way around?

A

All candidate keys are determinants but not all determinants are candidate keys

68
Q

Normalization: What is the preliminary step in normalization?

A

Get a user view

69
Q

exists when a nonkey attribute is functionally dependent
on part (but not all) of the primary key.

A

partial functional dependency

70
Q

Normalization:A functional dependency between
the primary key and one or
more nonkey attributes that are
dependent on the primary key via
another nonkey attribute.

A

transitive dependency

71
Q

Normalization: How to convert to 3rd normal form?

A
  1. Create a new relation
  2. Transfer all related attributes to the non pk
  3. Reference PK of new relation to the old relation
72
Q

Merging Relations: Is also called?

A

View integration

73
Q

Merging Relations: Two (or more) attributes that have
different names but the same
meaning

A

synonym

74
Q

Merging Relations:An alternative name used for an
attribute.

A

alias

75
Q

Merging Relations:An attribute that may have more
than one meaning

A

homonym

76
Q

A primary key whose value is
unique across all relations.

A

Enterprise Key

77
Q

Enterprise Key:This criterion makes a primary key more like what in object-oriented
databases is called

A

object identifier

78
Q

Enterprise Key: If a enterprise key is already available, what would happen to the “old pks”

A

they would become non key attributes

79
Q
A