Lecture 2: Entity Relationship Modelling Flashcards

1
Q

List four concepts of the ER Model

A
  1. Entity types
  2. Relationship Types
  3. Attributes
  4. Multiplicity
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

Why is conceptual design important?

A

It helps communicate database designs to non-technical users.

Also can be mapped as a relational schema.

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

What are the types of ER representations?

A
  1. Chen’s representation
  2. UML representation (mordern used)
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

What is an entity type?

A

Group of objects with same properties, identified as having an independent existence. Eg.. Beer

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

Define Entity Occurrence.

A

Uniquely identifiable object of an entity type

e.g. Beer - Summers, XXX, Extra Dry

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

Define what is a Relationship type.

Give an example.

A

Set of meaningful associations among entity types.

e.g. Song - “SING” - Artist

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

Explain Relationship Occurrence.

Give an example.

A

Uniquely identifiable association, which includes one occurrence from each participating entity type.

e.g. “humpty dumpty - SINGS - Adele”

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

Explain and give examples of “Degree of a Relationship”

Give examples of Each.

A

Number of participating entities in relationship.

  1. Degree 2: Binary
  • Artist sings song
  • Customer buys Beer
  1. Degree 3: Ternary
    * A waiter SERVES beer SERVES Customers
  2. Degree 4: Quaternary
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

Explain what a recursive relationship is.

A

Relationship type where same entity type participates more than once in different roles.

  • lisa FREINDS WITH Jane
  • Coke TASTES LIKE Pepsi
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

Explain characteristics of an Attribute.

A

Attribute: Property of an entity or a relationship type.

e.g “A car”

  • Year = 2010
  • Type = Sedan
  • Size = Small
  • Colour = Red
  • Number PLate = NULL
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

What is an attribute Domain?

A
  • Set of allowable values for one or more attributes
  • Similar domains in entity relationship model
  • Similar to data types in SQL
    • Not usually represented in ER Schemas.
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

What are composite Attributes?

A
  • Simple Attribute
    • Attribute composed of a single component with an independent existence
  • Composite Attribute
    • Attribute composed of multiple components, each with an independent existence
    • E.g. STAFF
      • ID
      • Name
        • First name
        • Middle Name
        • Last Name
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

Explain what a Multi-Valued attribute is.

A
  • Single Valued attribute
    • attribute that holds a single value for each occurrence of an entity type
  • Multi-valued attirbute
    • attribute that holds multiple values for each occurrence of an entity type
    • e.g STAFF
      • ID
      • Degrees[1..*]
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

Explain what a derived Attribute is

A

Attribute that represents a value that is derivable from value of a related attribute, or set of attributes, not neccarilly in the same entity type.

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

List and give definitions of KEYs:

  1. Candidate
  2. Primary
  3. Composite

​​

A

Candidate Key

  • Minimal set of attributes that uniquely identifies each occurrence of an entity type

Primary Key

  • Candidate key selected to uniquely identofy each occurrence of an entity type

Composite Key

  • A candidate key that consists of two or more attributes.
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

Structural Constraints: Multiplicity
Give an explanation

A
  • number (or range) of possible occurrences of an entity type that may relate to a single occurrence of an associated entity type through a particuler relationship
17
Q

Multiplicity in Binary Relationships. (binary is most common degree)

LIst the most common relationships.

A

Binary relationships are generally referred to as being:

  • one-to-one ( 1 : 1 )
  • one-to-many ( 1 : * )
  • many-to-many( * : * )
18
Q

Explain the two structural constraints.

A

Cardinality

Describes maximum number of possible relationship occurrences for an entity occurrence participating in a given relationship type. (MAX)

Participation

Determines whether all or only some entity occurrences participate in a relationship occurrence of the relationship type. (MIN)

19
Q

What is a FAn TRAP?

A

Where a model represents a relationship between entity types, but pathway between certain entity occurrences is ambigious.

20
Q

Explain Chasm Trap

A

where a model suggests the existence of a relationship between entity types, but pathway does not exist between certain entity occurrences.

21
Q

Quick review.

Define the following:

Entity types

Relationship types

Attributes

Multiplicity

A

Entity types: are group of objeccts with the same properties

Relationship types: are associations between entities

Attributes: are properties of entities or relationships

Multiplicity: of relationship types indicates participation and cardinality of connected entity types.