Data modeling
process used to define data requirements needed to support the business processes within organizations
Conceptual data model
technology-independent specification about the data
(during data modeling, data requirements are initially recorded as conceptual data model)
-constructed through collab with business stakeholders
physical data model
model that is used by the organization
entity relationship diagram (ERD) method
- includes three logical constructs: entities, attributes, and relationships
entities
-person, place, or thing about which an organization wishes to save information
EX: employee, state, order, and time sheet
-logical concept in the mind of the analyst that represents a category of objects that have common characteristics or attributes we want to store
attributes
-properties of entities that an organization cares about
EX: color, employment date, name, and SS number
-represents a fact that an organization wants to store for eacj instance of an entity
-EX: ID number first name, last name, birth date, employment date
relationships
instance
cardinality
one-to-one (1:1)
an instance of entity A can relate to one and only one instance of B and vice versa
EX: one wife has one husband
2 types: mandatory-participation relationships and optional-participation relationship
one-to-many (1:M)
one instance of entity A can relate to one or many instances of entity B, but an instance of entity B can only relate to instance A
EX: mother has many children, children have only 1 mother
-put the primary key from “one” side as a foreign key in the table on the “many” side of the relationship
many-to-many (M:M)
an instance of entity A can relate to one or more instances of entity B while instances of B can relate to one or more instances of entity A
EX: uncle has many nephews, nephews have many uncles
serialized instances
-each individual instance is assigned a unique identifier
EX: Cars have VIN (Vehicle Identification Number)
virtual instances
-same identifier is assigned to all the instances of that entity
EX: cereal, broom
table mapping
key migration
rules for which primary key from one side of the relationship becomes a foreign key on the other side of the relationship based on the cardinality of the relationship
mandatory-participation 1:1 relationship
there must be one record on each side of the relationship
optional-participation 1:1 relationship
participation on one side of the relationship is optional
primary key
simple key
key contains a single attribute
composite key
key that contains more than one attribute
semantic/natural key
key for which the possible values have an obvious meaning to the user or the data
artificial key
key for which the possible values have no obvious meaning to the user of the data