COMP2004 - DB Conceptual modelling Flashcards
Entity Relationship Diagram
Specify entities in a system along with their relationships
Conceptual modelling
- model objects
- identify;
Relationships btwn them
Their cardinality and participation
Identify strong and weak entities
Modelling
- objects - from nouns in UML
- attributes - properties of objects
- associations - relationships btwn objects
- cardinality - 1 to many, many to many
- participation - optional, mandatory
Weak entities
Can only exist in the presence of a strong entity ( composite notation)
so on UPDATE/DELETE CASCADE
Composite notation
It is only called composite if the objects it refers to are really its parts, i.e. have no independent existence. For details, see the aggregation section below.
High level model - Conceptual model
Understanding at a high level the different concepts in the system
Middle level model - Logical model
Adding details to the data - middle step between the two
Low level model - physical model
how it is implemented in the database
Functional dependency
Constraint btwn two sets of attributes in a relation from a database
Relation
Is a set of tuples where each element is a member of a data domain. Each distinct domain used in the definition of a relation is called an attribute
Relation
Attribute
| | | | |
—————————–
Tuple | | | | |
—————————–
| | | | |
—————————–
The whole thing is relation
Deriving tables
Objects become tables with the primary key chosen appropriately
Tuple/ Row
A sequence or ordered list of finite length
Column/Attribute
Defines properties of an individual
Relation
Table