Q4: the conceptual level
Concepts, Architecture and Conceptual Design (ER Model)
Levels of abstraction, schemas and instances, logical and physical data independence, then the ER model: entities and attribute types, keys, relationships, degree and cardinality ratios, total vs. partial participation, recursive relationships, weak entities, (min, max) notation and ternary relationships.
How to read this page
Every original slide is shown unchanged. Yellow marks on a slide point to a numbered note: hover or tap a mark to jump to its note, and hover a note to see its marks. Questions tagged Past exam appeared on a real paper; Prediction questions are likely angles, not confirmed. Pick an answer to each question: a wrong pick tells you why it is wrong, so you can try again.
All 69 slides
- 1 Conceptual Design (Entity–Relationship Model)
- 2 DATABASES SO FAR
- 3 LEARNING GOALS
- 4 PRELIMINARIES
- 5 Data abstraction
- 6 LEVELS OF ABSTRACTION
- 7 SCHEMAS AND INSTANCES
- 8 A database that stores student and course information.
- 9 SCHEMAS
- 10 DATA INDEPENDENCE
- 11 DATA INDEPENDENCE
- 12 DATA INDEPENDENCE
- 13 CONCEPTUAL DESIGN
- 14 ER COMPONENTS: ENTITIES AND ATTRIBUTES
- 15 ER COMPONENTS: ATTRIBUTE TYPES
- 16 EXAMPLE OF A COMPOSITE ATTRIBUTE
- 17 TYPES OF ATTRIBUTES: MULTI-VALUED
- 18 TYPES OF ATTRIBUTES: STORED AND DERIVED
- 19 TYPES OF ATTRIBUTES: COMPLEX ATTRIBUTES
- 20 ER COMPONENTS: KEYS
- 21 ER COMPONENTS: KEYS
- 22 MODELING ENTITIES IN ER DIAGRAMS
- 23 Slide 23
- 24 EXAMPLE: CAR ENTITY AND CAR ENTITY SET
- 25 ACTIVITY
- 26 EXAMPLE: COMPANY DATABASE
- 27 EXAMPLE COMPANY DATABASE (CONTINUED)
- 28 INITIAL CONCEPTUAL DESIGN OF ENTITY TYPES FOR THE COMPANY DATABASE SCHEMA
- 29 INITIAL DESIGN OF ENTITY TYPES
- 30 INITIAL DESIGN OF ENTITY TYPES
- 31 ER COMPONENTS: RELATIONSHIPS
- 32 RELATIONSHIP TYPE AND RELATIONSHIP SET
- 33 RELATIONSHIP DEGREES OR ARITY
- 34 RELATIONSHIP EXAMPLES
- 35 RELATIONSHIP CARDINALITY CONSTRAINTS
- 36 ONE TO ONE (1:1) RELATIONSHIPS
- 37 MANY TO ONE (N:1) RELATIONSHIPS
- 38 MANY TO MANY (M:N) RELATIONSHIPS
- 39 OTHER CONSTRAINTS ON RELATIONSHIPS
- 40 TOTAL AND PARTIAL PARTICIPATION
- 41 RECURSIVE RELATIONSHIP TYPE
- 42 DISPLAYING A RECURSIVE (UNARY) RELATIONSHIP
- 43 RECURSIVE (UNARY) RELATIONSHIP
- 44 DISCUSSION ON RELATIONSHIP TYPES
- 45 WEAK ENTITY TYPES
- 46 WEAK ENTITY TYPE
- 47 ATTRIBUTES OF RELATIONSHIP TYPES
- 48 REFINING THE COMPANY DATABASE SCHEMA BY INTRODUCING RELATIONSHIPS
- 49 Slide 49
- 50 many to one
- 51 ER DIAGRAM CONVENTIONS
- 52 ACTIVITY
- 53 CASE STUDY (SBS BANK)
- 54 ONE SOLUTION
- 55 ALTERNATIVE (MIN, MAX) NOTATION FOR RELATIONSHIP STRUCTURAL CONSTRAINTS:
- 56 THE (MIN,MAX) NOTATION FOR RELATIONSHIP CONSTRAINTS
- 57 COMPANY ER SCHEMA DIAGRAM USING
- 58 SUMMARY OF
- 59 RELATIONSHIPS OF HIGHER DEGREE
- 60 TERNARY RELATIONSHIPS
- 61 ALTERNATIVES TO
- 62 DISCUSSION OF N-ARY RELATIONSHIPS (N > 2)
- 63 DISCUSSION OF N-ARY RELATIONSHIPS (N > 2)
- 64 ANOTHER EXAMPLE OF A TERNARY RELATIONSHIP
- 65 DISPLAYING CONSTRAINTS ON HIGHER-DEGREE RELATIONSHIPS
- 66 ANOTHER EXAMPLE: A UNIVERSITY DATABASE
- 67 UNIVERSITY
- 68 CHAPTER SUMMARY
- 69 EXTENDED ENTITY-RELATIONSHIP (EER) MODEL (IN THE NEXT CHAPTER)
PRELIMINARIES
Notes
Three levels: physical (how data is stored), logical / conceptual (what data and relationships), view (part of the database for one user group).
LEVELS OF ABSTRACTION
Notes
Conceptual level hides the storage details and describes the whole database’s entities, data types, relationships and constraints.
Exam angle
What is TRUE about the conceptual level?
SCHEMAS AND INSTANCES
Exam angle
The database schema changes every time a row is inserted.
- The instance (state) changes; the schema stays.
DATA INDEPENDENCE
Notes
Data independence: change the schema at one level without changing the next higher level.
Exam angle
Q3: changing structures without breaking programs
Which lets you modify data structures without affecting existing programs?
DATA INDEPENDENCE
Notes
Logical data independence: change the conceptual schema (add a column) without changing external views/apps. Harder to achieve.
DATA INDEPENDENCE
Exam angle
Adding an index to speed up a query without changing the tables is an example of:
ER COMPONENTS: ATTRIBUTE TYPES
Notes
Attribute types: simple vs. composite, single- vs. multi-valued, stored vs. derived, complex.
TYPES OF ATTRIBUTES: MULTI-VALUED
Notes
Multi-valued attribute (double oval): several values, e.g. Colors of a car, Degrees.
TYPES OF ATTRIBUTES: STORED AND DERIVED
Notes
Derived attribute (dashed oval): computed from another, e.g. Age from BirthDate.
Exam angle
Age computed from BirthDate is a:
ER COMPONENTS: KEYS
Notes
Key attribute (underlined): unique for every entity in the set. An entity type may have several keys.
RELATIONSHIP CARDINALITY CONSTRAINTS
Notes
Cardinality ratio: 1:1, 1:N, M:N, the max number of relationship instances an entity can join.
Exam angle
Students take many courses and courses have many students. The cardinality is:
TOTAL AND PARTIAL PARTICIPATION
Notes
Total participation (double line): every entity must take part (existence dependency). Partial (single line): some may not.
Exam angle
"Every department must have a manager" is shown with:
WEAK ENTITY TYPES
Notes
Weak entity (double rectangle): no key of its own; identified by its owner through an identifying relationship (double diamond) + its partial key (dashed underline).
Trap A weak entity ALWAYS has total participation in its identifying relationship.
Exam angle
Q7: weak entity participation
A weak entity type always has ____ participation in its identifying relationship.
ALTERNATIVE (MIN, MAX) NOTATION FOR RELATIONSHIP STRUCTURAL CONSTRAINTS:
Notes
(min, max) notation: each entity takes part in at least min and at most max instances; min = 0 → partial, min ≥ 1 → total.
Exam angle
(1, N) next to EMPLOYEE on WORKS_FOR means each employee works for:
TERNARY RELATIONSHIPS
Notes
Ternary relationship: three entity types at once (SUPPLIER supplies PART to PROJECT). Not equivalent to three binary ones.