BIS II - Conceptual Data Modeling with ERDs Flashcards
Conceptual Data Modeling
- Representation of organizational data
- Purpose: to show rules about the meaning and interrelationships among data
- Entity-relationship (E-R) diagrams are commonly used to show how data are organized
- Main goal of conceptual data modeling is to create accurate E-R diagrams
- Methods, e.g. interviewing, questionnaire, and joint application design (JAD) are used to collect information
- Consistency must be maintained among process flow, decision logic, and data modeling descriptions
Introduction to entity-relationship modeling
- Notation uses three main constructs
o Data entities
o Relationships
o Attributes - Entity-relationship data model (E-R model)
o A detailed, logical, and graphical representation of the entities, associations and data elements for an organization or business - Entity-relationship diagram (E-R diagram)
o A graphical representation of an E-R model
E-R Modeling Key Terms
Definition - Entity
Entity = a person, place, object, event or concept in the user environment about which the organization wishes to maintain data; represented by a rectangle in E-R diagrams
E-R Modeling Key Terms
Definition - Entity-type
- Entity-type names
- Entity-type definitions
- A collection of entities that share common properties or characteristics
- Clearly naming & defining entity types are important tasks during data requirements, determination and structuring
o An entity type name should be…
A singular non, e.g. EMPLOYEE
Descriptive and specific to the organization e.g.. PURCHASE ORDER
Concise, e.g. REGISTRATION and not STUDENT REGISTRATION FOR CLASS
Should be for the result of the event, e.g. ASSIGNMENT and not ASSIGNING
o An entity type definition should include…
A statement what the unique characteristic(s) is (are) for each instance
A description what entity instances are included and not included in the entity type
A description when an instance of the entity type is created and deleted
A specification when an instance changes into an instance of another entity type
A specification what history is to be kept about entity instances
- Entity instance
o Single occurrence of an entity type
E-R modeling key terms: Attributes
- Each entity has a set of attributes associated with it
- Attribute:
o A property or characteristic of an entity that is of interest to the organization
o Represented by ellipse in E-R diagrams - Often several attributes have approximately the same name and meaning
ER - Modeling Key Terms: Attributes
name attributes using the following guidelines
o An attribute name is a noun
o should be unique
o should follow a standard format
o Similar attributes of different entity types should use similar but distinguishing names
ER - Modeling Key Terms: Attributes
An attribute definition…
o States what the attribute is and possibly why it is important
o Makes clear what is included and what is not included in the attribute’s value
o May specify any aliases, or alternative names
o Might state the source of values for the attributes
o Should indicate if a value is required or optional
o May indicate if a value for the attribute may change
o May indicate any relationships that attribute has with other attributes
ER - Modeling Key Terms: Attributes
- Candidate Keys
o Candidate key: attribute (or combination of attributes) that uniquely identifies each instance of an entity type
Each entity type must have an attribute or set of attributes that distinguishes one instance from other instances of the same type
o Identifier: a candidate key that has been selected as the unique identifying characteristic for an entity type
Selection rules:
• Choose a candidate key that will not change its value
• Choose a candidate key that will never be null
• Avoid using intelligent keys
• Consider substituting single value surrogate keys for large composite keys
ER - Modeling Key Terms: Attributes
- Other Attributes:
Multivalued attribute: attribute that may take on more than one value for each entity instance, e.g. employee skills; represented on E-R diagram in two ways:
• Double lined ellipse
• Weak entity
o Required attribute: an attribute that must have a value for every entity instance (underlined)
o Optional attribute: an attribute that may not have a value for every entity space (O) at the end
o Composite attribute: an attribute that has meaningful component parts
o Derived attribute: an attribute whose value can be computed from related attribute values, dotted ellipse
E-R Modeling Key Terms: Relationships
- Relationship - Definition
o An association between the instances of one or more entity types that is of interest to the organization
o Association indicates that an event has occurred or that there is a natural link between entity types
o Represented by diamonds in E-R diagrams
o Relationships are always labeled with verb phrases
E-R Modeling Key Terms: Relationships
- Types of Relationships
- Degree: number of entity types that participate in a relationship
- Unary relationship: a relationship between the instances of one entity type
- Binary relationships: a relationship between the instances of two entity types
- Ternary relationships: a simultaneous relationship among the instances of three entity types; not the same as three binary relationships
“Relationships” in E-R Diagrams
- A relationship should be…
o A verb phrase, usually in the present tense
o No vague names, such as Is_related_to - A Relationship definition:
o Explains what action is being taken and possibly why it is important
o May give examples or clarify the action
o Explain the reason for any explicit maximum cardinality
o Explain any restrictions on participation in the relationship
o Explain the extent of history that is kept in the relationship
o Explain whether an entity instance involved in a relationship instance can transfer participation to another relationship instance
Relationships - Related Terms
- Associative entity
An entity type that associates the instances of one or more entity types and contains attributes that are peculiar to the relationship between those entity instances - Participation and cardinality
The number of instances of entity B that can be associated with each instance of entity A
o Possible cardinalities: mandatory one; mandatory many; optional one; optional many - Minimum cardinality: the minimum number of instances of entity B that may be associated with each instance of entity A
- Maximum cardinality: the maximum number of instances of entity B that may be associated with each instance of entity A