Copyright © 2016 Pearson Education, Inc. Modern Database Management 12 th Edition Jeff Hoffer, Ramesh Venkataraman, Heikki Topi CHAPTER 2: MODELING DATA.

Slides:



Advertisements
Similar presentations
Database Systems: Design, Implementation, and Management Eighth Edition Chapter 4 Entity Relationship (ER) Modeling.
Advertisements

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.
Entity Relationship Model
CHAPTER 3: THE ENHANCED E-R MODEL © 2013 Pearson Education, Inc. Publishing as Prentice Hall 1 Modern Database Management 11 th Edition Jeffrey A. Hoffer,
Entity-Relation Modeling Hun Myoung Park, Ph.D., Public Management and Policy Analysis Program Graduate School of International Relations International.
Database Design & Mapping
Chapter 3: Modeling Data in the Organization
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
Fundamentals of Database Concepts
CHAPTER 2: MODELING DATA IN THE ORGANIZATION © 2013 Pearson Education, Inc. Publishing as Prentice Hall 1 Modern Database Management 11 th Edition Jeffrey.
Chapter 3 © 2005 by Prentice Hall 1 Objectives Definition of terms Definition of terms Importance of data modeling Importance of data modeling Write good.
Chapter 3: The Enhanced E-R Model
© 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.
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.
Chapter 3: Modeling Data in the Organization
Chapter 3: Modeling Data in the Organization
© 2011 Pearson Education, Inc. Publishing as Prentice Hall 1 Chapter 3: The Enhanced E-R Model Modern Database Management 10 th Edition Jeffrey A. Hoffer,
Copyright © 2011 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Chapter 4 Data Modeling Using the Entity- Relationship (ER) Model Hour1 Presented.
Chapter 2: Modeling Data in the Organization
MIS 385/MBA 664 Systems Implementation with DBMS/ Database Management Dave Salisbury ( )
Conceptual Data Modeling, Entity Relationship Diagrams
DATABASEMODELSDATABASEMODELS  A database model ◦ defines the logical design of data. ◦ Describes the relationships between different parts of data.
Chapter 2 © 2013 Pearson Education, Inc. Publishing as Prentice Hall CHAPTER 2: MODELING DATA IN THE ORGANIZATION Modern Database Management 11 th Edition.
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 2: MODELING DATA IN THE ORGANIZATION © 2013 Pearson Education, Inc. Publishing as Prentice Hall 1 Modern Database Management 11 th Edition Jeffrey.
1 Relational Databases and SQL. Learning Objectives Understand techniques to model complex accounting phenomena in an E-R diagram Develop E-R diagrams.
© Pearson Education Limited, Chapter 7 Entity-Relationship modeling Transparencies.
Chapter 4 Entity Relationship (ER) Modeling.  ER model forms the basis of an ER diagram  ERD represents conceptual database as viewed by end user 
CS 370 Database Systems Lecture 9 The Relational model.
Chapter 11 & 12 Entity-Relationship (E-R) Model Characteristics of E-R Model Components of E-R Model Example of E-R Model Enhanced E-R Model.
© 2009 Pearson Education, Inc. Publishing as Prentice Hall 1 Modeling Data in the Organization Chapters 3 + 4: Modern Database Management 9 th Edition.
3 & 4 1 Chapters 3 and 4 Drawing ERDs October 16, 2006 Week 3.
Chapter 2 © 2013 Pearson Education, Inc. Publishing as Prentice Hall Chapter 2: Modeling Data in the Organization Modern Database Management 11 th Edition.
Chapter 9: Logical Database Design and the Relational Model (ERD Mapping)
1 © Prentice Hall, 2002 Chapter 5: Logical Database Design and the Relational Model Modern Database Management 6 th Edition Jeffrey A. Hoffer, Mary B.
Carnegie Mellon University © Robert T. Monroe Management Information Systems Data Modeling Management Information Systems Robert.
CHAPTER 2: MODELING DATA IN THE ORGANIZATION © 2013 Pearson Education 1 Modern Database Management 11 th Edition, International Edition Jeffrey A. Hoffer,
Chapter 3: The Enhanced E-R Model
© 2011 Pearson Education 1 Chapter 3: Advanced Database Analysis Modern Database Management 10 th Edition, International Edition Jeffrey A. Hoffer, V.
CHAPTER 3: THE ENHANCED E-R MODEL © 2013 Pearson Education, Inc. Publishing as Prentice Hall 1 Modern Database Management 11 th Edition Jeffrey A. Hoffer,
MIS 385/MBA 664 Systems Implementation with DBMS/ Database Management
Chapter 3: Modeling Data in the Organization. Business Rules Statements that define or constrain some aspect of the business Assert business structure.
© 2009 Pearson Education, Inc. Publishing as Prentice Hall 1 Chapter 5 (Part a): Logical Database Design and the Relational Model Modern Database Management.
© 2009 Pearson Education, Inc. Publishing as Prentice Hall 1 Chapter 4: The Enhanced E-R Model Modern Database Management 9 th Edition Jeffrey A. Hoffer,
Copyright © 2016 Pearson Education, Inc. Modern Database Management 12 th Edition Jeff Hoffer, Ramesh Venkataraman, Heikki Topi CHAPTER 3: THE ENHANCED.
© 2009 Pearson Education, Inc. Publishing as Prentice Hall 1 Chapter 3: Modeling Data in the Organization Modern Database Management 9 th Edition Jeffrey.
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.
Chapter 3: Modeling Data in the Organization
Chapter 4: Logical Database Design and the Relational Model
Chapter 4: Part B Logical Database Design and the Relational Model
Overview of Entity‐Relationship Model
Entity-Relation Modeling
Chapter 3: Modeling Data in the Organization
Presentation transcript:

Copyright © 2016 Pearson Education, Inc. Modern Database Management 12 th Edition Jeff Hoffer, Ramesh Venkataraman, Heikki Topi CHAPTER 2: MODELING DATA IN THE ORGANIZATION

Chapter 2 Copyright © 2016 Pearson Education, Inc. 2-2 E-R MODEL CONSTRUCTS  Entity instance–person, place, object, event, concept (often corresponds to a row in a table)  Entity Type–collection of entity instance (often corresponds to a table)  Relationship instance–link between entity instance (corresponds to individual primary key-foreign key value match)  Relationship link between entity types (primary key-foreign key link) 2

Chapter 2 Copyright © 2016 Pearson Education, Inc. 2-3 Relationship degrees specify number of entity types involved Entity symbols A special entity that is also a relationship Relationship symbols Relationship cardinalities specify how many of each entity type is allowed Attribute symbols Basic E-R notation (Figure 2-2)

Chapter 2 Copyright © 2016 Pearson Education, Inc. 2-4 ATTRIBUTES  Attribute–property or characteristic of an entity or relationship type  Classifications of attributes:  Simple versus Composite Attribute  Single-Valued versus Multivalued Attribute  Stored versus Derived Attributes  Identifier Attributes 4

Chapter 2 Copyright © 2016 Pearson Education, Inc. 2-5 SIMPLE VS. COMPOSITE ATTRIBUTES  Composite attribute – An attribute that has meaningful component parts (attributes) The address is broken into component parts Figure 2-7 A composite attribute

Chapter 2 Copyright © 2016 Pearson Education, Inc. 2-6 Figure 2-8 Entity with multivalued attribute (Skill) and derived attribute (Years Employed) Multivalued an employee can have more than one skill Derived Calculated from date employed and current date MULTI-VALUED AND DERIVED ATTRIBUTES Multivalued – may take on more than one value for a given entity (or relationship) instance Derived – values can be calculated from related attribute values (not physically stored in the database)

Chapter 2 Copyright © 2016 Pearson Education, Inc. 2-7 IDENTIFIERS (KEYS)  Identifier (Key)–an attribute (or combination of attributes) that uniquely identifies individual instances of an entity type  Simple versus Composite Identifier 7

Chapter 2 Copyright © 2016 Pearson Education, Inc. 2-8 Figure 2-9 Simple and composite identifier attributes The identifier is boldfaced and underlined

Chapter 2 Copyright © 2016 Pearson Education, Inc. 2-9 STRONG VS. WEAK ENTITIES, AND IDENTIFYING RELATIONSHIPS  Strong entity  exists independently of other types of entities  has its own unique identifier  identifier underlined with single line  Weak entity  dependent on a strong entity (identifying owner)…cannot exist on its own  does not have a unique identifier (only a partial identifier)  entity box and partial identifier have double lines  Identifying relationship  links strong entities to weak entities

Chapter 2 Copyright © 2016 Pearson Education, Inc Strong entity Weak entity Figure 2-5 Example of a weak identity and its identifying relationship

Chapter 2 Copyright © 2016 Pearson Education, Inc MODELING RELATIONSHIPS  Relationship Types vs. Relationship Instances  The relationship type is modeled as lines between entity types…the instance is between specific entity instances  Two entities can have more than one type of relationship between them (multiple relationships) 11

Chapter 2 Copyright © 2016 Pearson Education, Inc Figure 2-10 Relationship types and instances a) Relationship type (Completes) b) Relationship instances

Chapter 2 Copyright © 2016 Pearson Education, Inc DEGREE OF RELATIONSHIPS  Degree of a relationship is the number of entity types that participate in it  Unary Relationship  Binary Relationship  Ternary Relationship

Chapter 2 Copyright © 2016 Pearson Education, Inc Degree of relationships – from Figure 2-2 Entities of two different types related to each other Entities of three different types related to each other One entity related to another of the same entity type

Chapter 2 Copyright © 2016 Pearson Education, Inc CARDINALITY OF RELATIONSHIPS  One-to-One: Each entity instance in the relationship will have exactly one related entity instance  One-to-Many: An entity instance on one side of the relationship can have many related entity instances, but an entity instance on the other side will have a maximum of one related entity instance.  Many-to-Many: An entity instance on either side of the relationship can have many related entity instances on the other side 15

Chapter 2 Copyright © 2016 Pearson Education, Inc Figure 2-12 Examples of relationships of different degrees a) Unary relationships

Chapter 2 Copyright © 2016 Pearson Education, Inc Figure 2-12 Examples of relationships of different degrees (cont.) b) Binary relationships

Chapter 2 Copyright © 2016 Pearson Education, Inc CARDINALITY CONSTRAINTS  Cardinality Constraints—the number of instances of one entity that can or must be associated with each instance of another entity  Minimum Cardinality  If zero, then optional  If one or more, then mandatory  Maximum Cardinality  The maximum number

Chapter 2 Copyright © 2016 Pearson Education, Inc Figure 2-17 Examples of cardinality constraints a) Mandatory cardinalities A patient must have recorded at least one history, and can have many A patient history is recorded for one and only one patient

Chapter 2 Copyright © 2016 Pearson Education, Inc Figure 2-17 Examples of cardinality constraints (cont.) b) One optional, one mandatory 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

Chapter 2 Copyright © 2016 Pearson Education, Inc Figure 2-17 Examples of cardinality constraints (cont.) c) Optional cardinalities A person is married to at most one other person, or may not be married at all

Chapter 2 Copyright © 2016 Pearson Education, Inc ASSOCIATIVE ENTITIES  An entity–has attributes  A relationship–links entities together 22

Chapter 2 Copyright © 2016 Pearson Education, Inc Figure 2-11a A binary relationship with an attribute Here, the date completed attribute pertains specifically to the employee’s completion of a course…it is an attribute of the relationship.

Chapter 2 Copyright © 2016 Pearson Education, Inc Figure 2-11b An associative entity (CERTIFICATE) Associative entity is like a relationship with an attribute, but it is also considered to be an entity in its own right. Note that the many-to-many cardinality between entities in Figure 2-11a has been replaced by two one-to-many relationships with the associative entity.

Chapter 2 Copyright © 2016 Pearson Education, Inc Figure 2-12 Examples of relationships of different degrees (cont.) c) Ternary relationship Note: a relationship can have attributes of its own

Chapter 2 Copyright © 2016 Pearson Education, Inc Figure 2-18 Cardinality constraints in a ternary relationship

Chapter 2 Copyright © 2016 Pearson Education, Inc Figure 2-22 Data model for Pine Valley Furniture Company in Microsoft Visio notation Different modeling software tools may have different notation for the same constructs.

Chapter 2 Copyright © 2016 Pearson Education, Inc. 2-28