Database Design Flashcards
Entities, relationships, and attributes. Cardinality. Strong and weak entities. Supertype and Subtypes. Modeling Conventions.
Entity-Relationship Model
High-level representation of data requirements, ignoring implementation details
Entity
Person, place, product, concept or activity
Relationship
Statement about two entities
Attribute
Descriptive property of an entity
Reflexive relationship
Relates to an entity itself
entity-relationship diagram, ER Diagram
schematic picture of entities, relationships, and attributes
Glossary/Data Dictionary/Repository
Documents additional detail in text format
Entity Type
a set of things Ex: All employees in a company.
Relationship Type
Is a set of related things (Employee-Manages-Department is a set of (employee, department) pairs, where the employee manages the department
Attribute Type
Set of values Ex: All employee salaries
Entity Instance
individual thing Ex: The employee Sam Snead
Relationship Instance
Statement about an entity instance Ex: “Maria Rodriguez manages Sales”
Attribute Instance
An individual value Ex: The Salary $35,000
Analysis
Develops an entity-relationship model, capturing data requirements while ignoring implementation details
Logical Design
Converts the entity-relationship model into tables, columns, and keys for a particular database system.
Physical design
Adds indexes and specifies how tables are organized on storage media
Cardinality
Refers to the maxima and minima of relationships and attributes
Relationship Maximum
Greatest number of instances of one entity that can relate to a single instance of another entity
Singular/Plural
Single when the maximum is one and plural when the maximum is many
Relationship Minimum
Least number of instances of one entity that can relate to a single instance of another entity
Optional/REquired
Optional when the minimum is zero and required when the minimum is one.
Attribute Maximum
Greatest number of attribute values that can describe each entity instance. Attribute maximum is usually specified as one singular or many plural
Attribute Minimum
last number of attribute values that can describe each entity instance. Attribute minimum is usually specified as zero or one required.
Unique Attribute
Describes at most one entity instance
Identifying attribute
unique, singular, and required
Identify
Values correspond to one-to-one to, or identify, entity instances.
strong entity
Has one or more identifying atytributes
Weak Entity/Identifying Relationship/Identifying entity
Weak entity usually has a relationship, called an identifying relationship, to another entity, called an identifying entity. Cardinality of the ID entity is 1(1)
Subtype Entity/Supertype Entity
Subtype entity is a subset of another entity type, called the supertype entity
IsA Relationship
A Super type entity identifies its subtype entities. The identifying relationship is called an IsA relationship
Similar Entities
Entities that have many common attributes and relationships
Partition
Supertype entity is a group of mutually exclusive subtype entities
Partition Attribute
Corresponds to an optional partition attribute of the super type entity
Crow’s Foot Notation
Depicts cardinality as a Circle(zero), a short line (one) or three short lines(many)
Subject Area
Decompose a complex model into a group of related entities, called a subject area
Independent/Dependent
Refers to strong entities as independent and weak entities as dependent
Unified Modeling Language/UML
Commonly used for software development. Software data structures are similar to database scructures, so UML includes ER conventions
IDEF1X
Information DEFinition Version 1x
Chen Notation
Chen notation is not standardized but often appears in literature and tools
Strong Table
Strong Entity becomes a strong table. Primary key must be unique and non-NULL, and should be stable, simple, and meaningless. Single-column primary keys are best. but if no such columns exists, a composite primary key may have the required properties.
Artificial Key
Single-Column primary key created by the database designer when no suitable single-column or composite primary key exists
Subtype Table
Subtype entity becomes a subtype table
Weak Table
Weak entity becomes a weak table
Depends on
Column A depends on Column B means each B value is related to at most one A value
Functional Dependence
Dependence of one column on another
Multivalued dependence/Join Dependence
Entail dependencies between three or more columns
Redundancy
Reptition of related values in a table