Conceptual Data Modeling, Entity Relationship Diagrams

Slides:



Advertisements
Similar presentations
Entity Relationship Diagrams
Advertisements

Entity Relationship (ER) Modeling
Systems Development Life Cycle
Data Modeling is an Analysis Activity
1 © Prentice Hall, 2002 Chapter 3: Modeling Data in the Organization Modern Database Management 6 th Edition Jeffrey A. Hoffer, Mary B. Prescott, Fred.
Modeling the Data: Conceptual and Logical Data Modeling
Database Design & Mapping
Chapter 3: Modeling Data in the Organization
Conceptual Data Modeling, E-R Diagrams. Outline  Purpose and importance of conceptual data modeling  Entity-Relationship Model Entity  Attributes Relationships.
DATABASE APPLICATION DEVELOPMENT SAK 3408
Chapter 3: Modeling Data in the Organization
Database Systems: Design, Implementation, & Management, 5 th Edition, Rob & Coronel 1 Data Models: Degrees of Data Abstraction l Modified ANSI/SPARC Framework.
CHAPTER 2: MODELING DATA IN THE ORGANIZATION © 2013 Pearson Education, Inc. Publishing as Prentice Hall 1 Modern Database Management 11 th Edition Jeffrey.
Chapter 4 Entity Relationship (E-R) Modeling
Chapter 3 © 2005 by Prentice Hall 1 Objectives Definition of terms Definition of terms Importance of data modeling Importance of data modeling Write good.
Database Management COP4540, SCS, FIU Database Modeling Using the Entity-Relationship Model (Chapter 3)
© 2007 by Prentice Hall (Hoffer, Prescott & McFadden) 1 Entity Relationship Diagrams (ERDs)
1 © Prentice Hall, 2002 Chapter 3: Modeling Data in the Organization Modern Database Management 7th Edition Jeffrey A. Hoffer, Mary B. Prescott, Fred R.
1 © Prentice Hall, 2002 CMIS564: E/R Modeling Dr. Bordoloi Based on Chapter 3; Modern Database Management 6 th Edition Jeffrey A. Hoffer, Mary B. Prescott,
1 © Prentice Hall, 2002 Chapter 3: Modeling Data in the Organization Modern Database Management 6 th Edition Jeffrey A. Hoffer, Mary B. Prescott, Fred.
1 Web-Enabled Decision Support Systems Entity-Relationship Modeling Prof. Name Position (123) University Name.
3.1 CSIS 3310 Chapter 3 The Entity-Relationship Model Conceptual Data Modeling.
© 2011 Pearson Education, Inc. Publishing as Prentice Hall 1 Chapter 2: Modeling Data in the Organization Modern Database Management 10 th Edition Jeffrey.
the Entity-Relationship Model
Chapter 3: Modeling Data in the Organization
Chapter 3: Modeling Data in the Organization
Database. Basic Definitions Database: A collection of related data. Database Management System (DBMS): A software package/ system to facilitate the creation.
Module Title? Data Base Design 30/6/2007 Entity Relationship Diagrams (ERDs)
1 ER Modeling BUAD/American University Entity Relationship (ER) Modeling.
Chapter 2: Modeling Data in the Organization
MIS 385/MBA 664 Systems Implementation with DBMS/ Database Management Dave Salisbury ( )
McGraw-Hill/Irwin © 2008 The McGraw-Hill Companies, All Rights Reserved Plug-In T5: Designing Database Applications Business Driven Technology.
©Silberschatz, Korth and Sudarshan2.1Database System Concepts Chapter 2: Entity-Relationship Model Entity Sets Relationship Sets Design Issues Mapping.
CHAPTER 2: MODELING DATA IN THE ORGANIZATION © 2013 Pearson Education, Inc. Publishing as Prentice Hall 1 Modern Database Management 11 th Edition Jeffrey.
© 2011 Pearson Education, Inc. Publishing as Prentice Hall 1 Chapter 2: Modeling Data in the Organization.
Chapter 4 Entity Relationship (ER) Modeling.  ER model forms the basis of an ER diagram  ERD represents conceptual database as viewed by end user 
Initial Design of Entity Types for the COMPANY Database Schema Based on the requirements, we can identify four initial entity types in the COMPANY database:
Carnegie Mellon University © Robert T. Monroe Management Information Systems Data Modeling Management Information Systems Robert.
UNIT_2 1 DATABASE MANAGEMENT SYSTEM[DBMS] [Unit: 2] Prepared By Lavlesh Pandit SPCE MCA, Visnagar.
Entity Relationship Modeling
MIS 385/MBA 664 Systems Implementation with DBMS/ Database Management
Data Modeling Using the Entity-Relationship (ER) Data Model.
Chapter 3: Modeling Data in the Organization. Business Rules Statements that define or constrain some aspect of the business Assert business structure.
©Silberschatz, Korth and Sudarshan7.1Database System Concepts - 6 th Edition Chapter 7: Entity-Relationship Model.
Copyright © 2016 Pearson Education, Inc. Modern Database Management 12 th Edition Jeff Hoffer, Ramesh Venkataraman, Heikki Topi CHAPTER 2: MODELING DATA.
© 2009 Pearson Education, Inc. Publishing as Prentice Hall 1 Chapter 3: Modeling Data in the Organization Modern Database Management 9 th Edition Jeffrey.
McGraw-Hill/Irwin Copyright © 2006 by The McGraw-Hill Companies, Inc. All rights reserved. Chapter 6 Modeling the Data: Conceptual and Logical Data Modeling.
Pree Thiengburanathum, CAMT, Chiang Mai University 1 Database System Modeling Data in the Organization October 31, 2009 Software Park, Bangkok Thailand.
Chapter 2: Modeling Data in the Organization
Chapter 3 1 Chapter 3: Modeling Data in the Organization.
IS 4420 Database Fundamentals Chapter 3: Modeling Data in the Organization Leon Chen.
© 2009 Pearson Education, Inc. Publishing as Prentice Hall 1 Lecture 3: Modeling Data in the Organization Modern Database Management 9 th Edition Jeffrey.
Database Designsemester Slide 1 Database Design Lecture 7 Entity-relationship modeling Text , 7.1.
Entity-Relationship Model
Entity Relationship Model
Entity-Relationship Model
Chapter 7 Entity-Relationship Model
Outline of the ER Model By S.Saha
Logical Data Modeling.
Overview of Entity‐Relationship Model
Entity Relationship Diagrams
Database Systems: Design, Implementation, and Management Tenth Edition
Review of Week 1 Database DBMS File systems vs. database systems
Chapter 3: Modeling Data in the Organization
Entity-Relationship Diagram (ERD)
Entity Relation Model Tingting Zhang.
ER MODELING Instructor: SAMIA ARSHAD
Presentation transcript:

Conceptual Data Modeling, Entity Relationship Diagrams

Importance of Conceptual Data Modeling Data rather than processes are more complex in many modern information systems. Characteristics of data (structure, properties) are more stable, i.e. less likely to change over time, easier to reach consensus on. It is shared between many processes, therefore is crucial in the design of databases, ensuring integrity of the data in an information system, efficiency of processing.

An Entity An ENTITY or (Entity Type) is something of interest in the environment (e.g., person, place, object, event, concept), characterized with ATTRIBUTES. Represented in E-R diagram by a rectangle An ENTITY INSTANCE is a particular occurrence of an entity type – NOT SHOWN ON ERDs. ENTITY ~ Table ATTRIBUTE ~ Column in a table ENTITY INSTANCE ~ Row in a table

An Attribute A discrete data element A characteristic (property) of an entity CUSTOMER Customer_Number Last_Name First_Name Street_Address City State Zip Phone This Customer entity  has eight attributes

Example: identify Entity, Attributes, Instances Customer Cust_ID Last_Name First_Name Address City ST Zip 0001 Snerd Mortimer General Delivery Tampa FL 33647 0002 Fogg Bob 567 Fogg Lane Omaha NE 32405 0003 Amos Famous 2 Cookie Ct. Miami FL 33133 0004 Targa Maxine 67 Fast Lane Clinton NJ 20082 0005 George Scott 56 Neat St. Boulder CO 35882 0006 Guy Nice 290 Pleasant St. Tampa FL 33641 0007 Smith Bob 76 Quaker Path Wynn NY 21118 0009 Smith James 234 Bayview Tampa FL 33641

What Should an Entity Be? SHOULD BE: An object that is important to business An object that will have many instances in the database An object that will be composed of multiple attributes SHOULD NOT BE: Data that is not used by the application, should not be stored in the database.

Types of Attributes Stored vs Derived (e.g. DateOfBirth vs Age) Simple vs. Composite Simple - most basic level Composite – decomposable into a group of related attributes ex: address (street, city, state, zip) Single Valued vs. Multi Valued – Single - only one value per entity instance (e.g., last name, date of birth) Mulitvalued- multiple values per entity instance (e.g., degrees, clubs, skills) Stored vs Derived (e.g. DateOfBirth vs Age)

Attributes notation Simple

An attribute broken into component parts Textbook’s notation An attribute broken into component parts Multivalued an employee can have more than one skill Derived from date employed and current date 9

Alternative notation Multivalued attributes are shown as double ellipses Composite attributes may be shown broken down into their simple components Simple/Single Valued; identifier Multivalued EMPLOYEE emp-id name skill f_name l_name m_name composite

Example: time stamping 37

Identifier Attributes Every instance of an entity must be uniquely identified (to unambiguously distinguish them) Simple identifier consists of one attribute Composite identifier consists of more than one attribute (e.g., first name, middle name, and last name) Partial identifier (in weak entities) – attribute that together with some attribute from another entity identifies an instance Underline identifiers in diagrams Double underline partial identifiers

Identifiers Value of identifier must be unique for each entity instance Should not change value over time Guaranteed to have a valid value No intelligent identifiers (e.g. containing locations or people that might change) Consider substituting single-attribute artificial identifiers for natural composite identifiers to simplify design and enhance performance

Simple vs composite identifiyer

Relationships A relationship is an association between one or more entities The degree of a relationship indicates the number of entities involved The cardinality of a relationship describes the number of instances of one entity associated with another entity

Cardinality Constraints Cardinality Constraints - the number of instances of one entity that can or must be associated with each instance of another entity. 0 Optional relationships 0 or one 0 or many Mandatory relationships one and only one one or more

Example An employee can be assigned to any number of projects, or may not be assigned to any at all A project must be assigned to at least one employee, and may be assigned to many

Degrees of Relationships: unary, binary, ternary The number of different entities involved in a relationship

More on Relationships Relationships (many-to-many or one-to-one) can have attributes These describe features pertaining to the association between the entities in the relationship Two entities can have more than one type of relationship between them (multiple relationships) Associative Entity = combination of relationship and entity

Entities can be related to one another in more than one way Figure 3-21a Employees and departments 40

Degrees of Relationships - ternary A vendor supplies parts to warehouses. The unit cost and delivery method may differ for every warehouse. Note: a relationship can have attributes of its own 24

More on Entities: Strong vs. Weak Entities Strong entities exist independently of other types of entities has its own unique identifier represented with single-line rectangle Weak entity dependent on a strong entity…cannot exist on its own Does not have a unique identifier represented with double-line rectangle Identifying relationship links strong entities to weak entities represented with double line diamond

Associative Entities Associative entities provide details of a many-to-many association. It’s an entity – it has attributes AND it’s a relationship – it links entities together When should a many-to-many relationship with attributes instead be converted into an associative entity? The associative entity could have meaning independent of the other entities The associative entity preferably has a unique identifier, and should also have other attributes The associative entity may participate in other relationships other than the entities of the associated relationship

Example:many-to-many relationship with attributes vs Example:many-to-many relationship with attributes vs. associative entity 21

Associative entity – other notation Associative entity is depicted as a rectangle with a diamond inside. 21

Modeling a ternary relationship as an associative entity 36

SUMMARY of basic E-R notation 8

Alternative ER Model Notation Entity Attribute Relationship 2