ER Modeling Flashcards

(55 cards)

1
Q

Miniworld

A

part of the real world that we are interested in modeling

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

What is the importance of conceptual design?

A
  • Fundamental
  • Involves users
  • Provides good documentation for the Db
  • Independent of the DBMS
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

What is the Entity-Relationship (ER) model?

A

Notion that a database can be modelled as a collection of entity classes and relationships among them

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

What is the goal of the ER model?

A

Develop an ER schema or ER diagram

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

Entity

A

Data object that exists and is distinguishable from other objects

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

What can be considered entities?

A

An object that physically exists, abstract or organizational entity, or an event

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

Entity type

A

description of the attributes that a set of entities has in common

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

Entity set

A

A collection of of entities of the same type

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

Entity class

A

combination of entity set + entity type

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

Attribute

A

Property of an entity

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

All members of an entity class will have the same ______

A

Attributes
But they may have different attribute values
(e.g. all customers will have a name but the name will likely be different)

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

How is an entity class represented?

A

A rectangle

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

How is an attribute represented?

A

labelled oval connected to a entity class

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

How are entities distinguished from one another?

A

Each entity will have a unique combination of attribute values

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

Candidate Identifier

A

a set of one or more attributes whose values uniquely determine each entity.

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

Can you have more than one candidate identifier?

A

Yes there can be several

Ex: Name, DOB of customers, customerid of customers

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

Can you have more than one primary identifier?

A

No. One candidate identifier is selected to be the primary identifier

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

What conditions must be met for a primary identifier?

A
  • Unique
  • Mandatory
  • Time invariant
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
19
Q

How are primary identifier represented?

A

Labelled oval with an underline

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

How are null values represented? When are they used?

A

@ symbol

For unknown or inapplicable values

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

How are multi-valued attributes represented? What is an example?

A

Double oval

Customer could have more than 1 phone number

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

What is a composite attribute? What is the opposite of a composite attribute?

A

A composite attribute is comprised of multiple values to describe it (e.g. address has street, city, zip etc.)
The opposite of a composite is a simple

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

What is a derived attribute? How is it represented? What is the opposite of a derived attribute?

A

The opposite of derived is stored. It is an attribute that is calculated from another attribute. It’s represented with a dotted oval. An example being age calculated from date of birth attribute

24
Q

Where are characteristics captured that are not typically represented in the ER diagram? What are some examples?

A

Data dictionary

  • Attribute cardinality
  • Entity class cardinality
  • Attributes that are optional or mandatory, attribute uniqueness
  • Domain constraints (e.g SSN must be 9 exactly)
25
Cardinality
Number of elements in that set
26
Cardinality constraint
bounds the upper and/or lower limits of the cardinality
27
What does a cardinality constraint do for an attribute?
Restricts the number of values an attribute can take on
28
Interaction relationship
association between or among entities
29
Relationship type
is a list (ordered) of participating entity classes
30
Relationship set
specific set of associated entity instances based on relationship type
31
Relationship Class
relationship type + relationship set
32
How is a relationship class represented?
Diamond
33
Can a relationship class have attributes?
No
34
How is data that exists due to the relationship classified as?
Weak entity | The data has no meaningful existence without the relationship that defines it (e.g order details)
35
What is the purpose of a weak entity?
Provide more data about the interaction between the 2 entities
36
Degree of an interaction relationship
Number of entity classes involved in a relationship
37
What are examples of interaction relationships?
unary binary ternary
38
Business Rule
business policy that leads to a rule/statement constraining some aspect of the business
39
Where are Business rules and other or behavior-oriented/process oriented rules located?
Annotations on the ER or data dictionary
40
Weak entity class
inherits identifying attributes from another entity class to uniquely identify its own entities
41
How is a weak entity class represented?
Double lined box and an arrow pointing to the identifying relationship
42
What is the defining characteristic of a weak entity?
If an entity class depends on another class for all or part of its identifier, it's weak
43
When does a weak entity have a partial identifier?
If the max cardinality > 1 in its identifying relationship
44
How is a partial identifier represented?
Dotted underline
45
What is the circle relationship symbol?
Indicates a superclass and associated subclass
46
Designation
Classifying attribute for the superclass/subclass relationship
47
What are the 4 types of superclass/subclass relationships
Disjoint, 0:1 Partition, 1:1 Overlap, 0:M Cover, 1: M
48
Disjoint superclass/subclass relationship
0:1 relationship Example: an employee may not be an associate or a manager (just in the general employee pool)
49
Partition
1:1 Example: Employee must either be a manager or an associate. No employee can be both
50
Overlap
0:M | An employee can be both a manager and an engineer (or could be neither)
51
Cover
1:M | Employee has to be either a manager or engineer or could be both (can't be neither)
52
When to create subclasses
- Attributes relative only to a subclass - Relationship classes relevant only to a subclass - Cardinality of relationships associated with subclasses are different
53
How do subclasses gain attributes and relationships?
They are inherited from the superclass (including the identifier)
54
Specific attributes
attributes to the subclass only
55
Specific relationships
entities in a subclass participating in direct relationships