CHAPTER 2: MODELING DATA IN THE ORGANIZATION © 2013 Pearson Education, Inc. Publishing as Prentice Hall 1 Modern Database Management 11 th Edition Jeffrey.

Slides:



Advertisements
Similar presentations
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.
Modeling the Data: Conceptual and Logical Data Modeling
Entity Relationship Model
© 2002 by Prentice Hall 1 David M. Kroenke Database Processing Eighth Edition Chapter 3 The Entity- Relationship Model.
Copyright © 2012 Pearson Education, Inc. Publishing as Prentice Hall 7.1.
Entity-Relation Modeling Hun Myoung Park, Ph.D., Public Management and Policy Analysis Program Graduate School of International Relations International.
Database Design & Mapping
System Analysis - Data Modeling
Chapter 3: Modeling Data in the Organization
DATABASE APPLICATION DEVELOPMENT SAK 3408
Chapter 3: Modeling Data in the Organization
Chapter 2: Modeling Data in the Organization
Copyright © 2012 Pearson Education, Inc. Publishing as Prentice Hall 7.1.
Chapter 4 Entity Relationship (ER) Modeling
Chapter 8 Structuring System Data Requirements
Chapter 3 © 2005 by Prentice Hall 1 Objectives Definition of terms Definition of terms Importance of data modeling Importance of data modeling Write good.
Copyright 2002 Prentice-Hall, Inc. Modern Systems Analysis and Design Third Edition Jeffrey A. Hoffer Joey F. George Joseph S. Valacich Chapter 10 Structuring.
© 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.
Copyright © 2012 Pearson Education, Inc. Publishing as Prentice Hall 7.1.
© 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
Copyright © 2009 Pearson Education, Inc. Publishing as Prentice Hall Essentials of Systems Analysis and Design Fourth Edition Joseph S. Valacich Joey F.
Chapter 2: Modeling Data in the Organization
MIS 385/MBA 664 Systems Implementation with DBMS/ Database Management Dave Salisbury ( )
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.
© 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 
© 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.
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.
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.
1 © Prentice Hall, 2002 ITD1312 Database Principles Chapter 4B: Logical Design for Relational Systems -- Transforming ER Diagrams into Relations Modern.
© 2009 Pearson Education, Inc. Publishing as Prentice Hall 1 Chapter 5 (Part a): Logical Database Design and the Relational Model Modern Database Management.
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.
Copyright 2002 Prentice-Hall, Inc. Modern Systems Analysis and Design Third Edition Jeffrey A. Hoffer Joey F. George Joseph S. Valacich Chapter 10 Structuring.
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.
Converting ER/EER to logical schema; physical design issues 1.
Chapter 3: Modeling Data in the Organization
Modeling data in the Organization
Chapter 10 Structuring System Requirements: Conceptual Data Modeling
Chapter 4: Logical Database Design and the Relational Model
Chapter 4: Part B Logical Database Design and the Relational Model
Chapter 7 Structuring System Requirements: Conceptual Data Modeling
Overview of Entity‐Relationship Model
Chapter 10 Structuring System Requirements: Conceptual Data Modeling
Review of Week 1 Database DBMS File systems vs. database systems
Chapter 3: Modeling Data in the Organization
Presentation transcript:

CHAPTER 2: MODELING DATA IN THE ORGANIZATION © 2013 Pearson Education, Inc. Publishing as Prentice Hall 1 Modern Database Management 11 th Edition Jeffrey A. Hoffer, V. Ramesh, Heikki Topi

Chapter 2 © 2013 Pearson Education, Inc. Publishing as Prentice Hall OBJECTIVES  Define terms  Write good names and definitions for entities, relationships, and attributes  Model different types of attributes and entities,  Introduce the concept of relationships, and cardinalities  Draw E-R diagrams for common business situations 2

Chapter 2 © 2013 Pearson Education, Inc. Publishing as Prentice Hall A GOOD DATA NAME IS:  Related to b usiness, not technical, characteristics  Meaningful and self-documenting  Unique  Written in standard syntax  Data Definitions  Provide a concise description of essential data meaning 3

Chapter 2 © 2013 Pearson Education, Inc. Publishing as Prentice Hall E-R MODEL CONSTRUCTS  Entities:  Entity instance–person, place, object, event, concept (often corresponds to a row in a table)  Entity Type–collection of entities (often corresponds to a table)  Relationships:  Relationship instance–link between entity instances (corresponds to primary key-foreign key equivalencies in related tables)  Relationship type–category of relationship…link between entity types  Attributes:  Properties or characteristics of an entity or relationship type (often corresponds to a field in a table) 4

Chapter 2 © 2013 Pearson Education, Inc. Publishing as Prentice Hall ENTITIES  Entity –  a person, a place, an object, an event, or a concept in the user environment about which the organization wishes to maintain data  Entity type –  a collection of entities that share common properties or characteristics  Entity instance –  A single occurrence of an entity type 5

Chapter 2 © 2013 Pearson Education, Inc. Publishing as Prentice Hall ENTITY TYPE AND ENTITY INSTANCES 6

Chapter 2 © 2013 Pearson Education, Inc. Publishing as Prentice Hall AN ENTITY…  SHOULD BE:  An object that will have many instances in the database  An object that will be composed of multiple attributes  An object that we are trying to model  SHOULD NOT BE:  A user of the database system  An output of the database system (e.g., a report) 7

Chapter 2 © 2013 Pearson Education, Inc. Publishing as Prentice Hall 8 Inappropriate entities Systemuser System output Figure 2-4 Example of inappropriate entities Appropriate entities

Chapter 2 © 2013 Pearson Education, Inc. Publishing as Prentice Hall ATTRIBUTES  Attribute–property or characteristic of an entity or relationship type  Classifications of attributes:  Required versus Optional Attributes  Simple versus Composite Attribute  Single-Valued versus Multivalued Attribute  Stored versus Derived Attributes  Identifier Attributes 9

Chapter 2 © 2013 Pearson Education, Inc. Publishing as Prentice Hall SIMPLE VS. COMPOSITE ATTRIBUTES  Composite attribute – An attribute that has meaningful component parts (attributes) 10 The address is broken into component parts Figure 2-7 A composite attribute

11 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) 11 Chapter 2 © 2013 Pearson Education, Inc. Publishing as Prentice Hall

Chapter 2 © 2013 Pearson Education, Inc. Publishing as Prentice Hall IDENTIFIERS (KEYS)  Identifier (Key)–an attribute (or combination of attributes) that uniquely identifies individual instances of an entity type  Simple versus Composite Identifier  Candidate Identifier–an attribute that could be a key…satisfies the requirements for being an identifier 12

Chapter 2 © 2013 Pearson Education, Inc. Publishing as Prentice Hall CRITERIA FOR IDENTIFIERS  Choose Identifiers that  Will not change in value  Will not be null  Avoid intelligent identifiers (e.g., containing locations or people that might change)  Substitute new, simple keys for long, composite keys 13

Chapter 2 © 2013 Pearson Education, Inc. Publishing as Prentice Hall BUSINESS RULES  Are statements that define or constrain some aspect of the business  Are derived from policies, procedures, events, functions  Assert business structure  Control/influence business behavior  Are expressed in terms familiar to end users  Are automated through DBMS software 14 If possible

Chapter 2 © 2013 Pearson Education, Inc. Publishing as Prentice Hall E-R MODEL CONSTRUCTS  Entities:  Entity instance–person, place, object, event, concept (often corresponds to a row in a table)  Entity Type–collection of entities (often corresponds to a table)  Relationships:  Relationship instance–link between entity instances (corresponds to primary key-foreign key equivalencies in related tables)  Relationship type–category of relationship…link between entity types  Attributes:  Properties or characteristics of an entity or relationship type (often corresponds to a field in a table) 15

Chapter 2 © 2013 Pearson Education, Inc. Publishing as Prentice Hall MODELING RELATIONSHIPS  Relationship Types vs. Relationship Instances  The relationship type is modeled as lines between entity types…the instance is between specific entity instances 16

17 Figure 2-10 Relationship types and instances a) Relationship type (Completes) b) Relationship instances 17 Chapter 2 © 2013 Pearson Education, Inc. Publishing as Prentice Hall

18 Sample E-R Diagram (Figure 2-1) 18 Chapter 2 © 2013 Pearson Education, Inc. Publishing as Prentice Hall

Chapter 2 © 2013 Pearson Education, Inc. Publishing as Prentice Hall DEGREE OF RELATIONSHIPS  Degree of a relationship is the number of entity types that participate in it  Unary Relationship  Binary Relationship  Ternary Relationship 19

20 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 20 Chapter 2 © 2013 Pearson Education, Inc. Publishing as Prentice Hall

Chapter 2 © 2013 Pearson Education, Inc. Publishing as Prentice Hall CARDINALITY OF RELATIONSHIPS  One-to-One  Each entity in the relationship will have exactly one related entity  One-to-Many  An entity on one side of the relationship can have many related entities, but an entity on the other side will have a maximum of one related entity  Many-to-Many  Entities on both sides of the relationship can have many related entities on the other side 21

Chapter 2 © 2013 Pearson Education, Inc. Publishing as Prentice Hall 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 22

23 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 23 Chapter 2 © 2013 Pearson Education, Inc. Publishing as Prentice Hall

24 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 24 Chapter 2 © 2013 Pearson Education, Inc. Publishing as Prentice Hall

25 Figure 2-12 Examples of relationships of different degrees (cont.) b) Binary relationships 25 Chapter 2 © 2013 Pearson Education, Inc. Publishing as Prentice Hall