Presentation is loading. Please wait.

Presentation is loading. Please wait.

FEN 2014-03-231  Conceptual modelling: The Entity-Relation (ER) Model Conceptual models Entity – Relation (ER) models.

Similar presentations


Presentation on theme: "FEN 2014-03-231  Conceptual modelling: The Entity-Relation (ER) Model Conceptual models Entity – Relation (ER) models."— Presentation transcript:

1 FEN 2014-03-231  Conceptual modelling: The Entity-Relation (ER) Model Conceptual models Entity – Relation (ER) models

2 …or… Where does all the tables come from??? FEN 2014-03-232

3 Conceptual Data Models A conceptual data model describes the data objects (entities) and their relations in the problem domain. A conceptual model of the data is the basis on which the IT systems of an organisation are based. It should be: Independent of implementation Stable over time Over time conceptual data structure doesn't change nearly as much as functionality Conceptual models are to be transformed to a database model as the relational model. FEN 2014-03-233

4 Example: MiniBank This is implementation: FEN 2014-03-234 What would a conceptual model look like? Entities? Customer Account Relations: Customer-Owns-Account CustomerAccount custNo name accNo balance inRate Owns 1 n

5 Entity-Relation (ER) Model: Concepts Entities Attributes ⋅ Atomic ⋅ Composite ⋅ Multi valued Attribute values Entity types Keys Domains FEN 2014-03-235 Relations Cardinality ratio Participation (total / partial) Relations may have attributes Weak Entity Types Identifying owner Identifying relation Partial key A weak entity always has total participation in the identifying relation. CustomerAccount custNo name accNo balance inRate Owns 1 n

6 Example: The Company Database (Elmasri) FEN 2014-03-236

7 Entities? FEN 2014-03-237 Department: name(kk), number(kk), location Project: name(kk), number(kk), location Employee: ssn(kk), bdate, name (poss. composite), sex, address (poss. composite), salary Dependent (weak?): name (partial key), sex, bdate Example: The Company Database (Elmasri)

8 Relations? FEN 2014-03-238 Manages Works_For Works_On Dependents_Of Supervision Controls Example: The Company Database (Elmasri)

9 ER Diagram for the Company Database FEN 2014-03-239 Example: The Company Database (Elmasri) Note the similarities to UML domain models - more on this later

10 Relations of Degree > 2 FEN 2014-03-2310 Often causes problem in database design May be transformed to binary relations or entities Not to be considered in this introduction

11 Example/Exercise (Elmasri) FEN 2014-03-2311 Questions: Can a customer exists without an account? Can an account have more owners? How many branches can account belong to? Can a customer have accounts in more than one branch? …???


Download ppt "FEN 2014-03-231  Conceptual modelling: The Entity-Relation (ER) Model Conceptual models Entity – Relation (ER) models."

Similar presentations


Ads by Google