Exam Flashcards
Data Redundancy
when data is stored in different places unnecessarily. E.g when you record names & numbers different places.
Data Independance
Making changes to the way file characteristics are stored without affecting the programs ability to access data. e.g Usually lacking in file systems coz most programs change when data characteristics change.
DBMS
Database Management System
DBMS Functions
Eliminate data inconsistency, stop data anormaly, Data Dictionary Management, Data transformation, Security Management etc
Structural Independance
When you can change the file structure without affecting the data access.
Data
raw facts
Information
Result of processing data to reveal meaning
DBMS Role
A link between the user & the Database.
+s promotes data sharing, Eliminates problems islands of info, enforces data integrity,stops redundancy,promotes security
Metadata
Data about data
Spreadsheets cannot
Support self-doccumentation through metadata,enforcement of data types or domains to ensure consistency in columns, define relationships among tables, or constraints to make consistent on related tables.
Data Modelling is important because
Designers use to communicate with programmers and end users of a database. Main function is understanding complexities of real world environment.
A Business Rule
A short,precise and unambiguous description of a policy, procedure or principal that applies to an organization.
Business Rule purpose
To define entities,attributes, relationships and constraints.
Translating business rules
noun= entity verb= relationship between entities
Relationship
Describes and association between entities
Three types of relationships
1:M 1 to many, M:N Many to many, 1:1 one to one
A Weak Entity must
- Be existence dependant
2. The entity must have a PK that is partially or totally from the parent entity.
Strong(or identifying) relationship
PK of related entities contains a PK component of parent entity. Shown bold line ERD
Composite Entity
Is in a 1:M relationship with the parent entities and is made up of the pk attributes of the parent entity.
Used to represent/solve a M:N relationship between 2 or more entities.
Recursive Relationship
when a relationship can exist between occurances of the same entity set. eg an employee is a manager of a store.
Entity Supertype
A generic entity type that is related to one or more entity subtypes. Used to: avoid nulls when one supertype might have different characteristics than another.
Example of 1:M Relationship
One cook can make many burgers and each burger can be made by many cooks.
Example of M:N realtionship
A student can take many classes and each class can have many students.
Example of 1:1 relationshiop
Each store is managed by one employee and each manager manages only one store.
Logical independence
when you can change the internal model without affecting the conceptual model
Physical independance
when you can change the physical model without affecting the internal model
Difference between a database and a table
A database is made up of/holds tables and a table resembles a file conceptually.
Entity Integrity
Each row (entity) in the table has its own unique identity(PK)
referential Integrity
When the FK consists of a value that refers to an existing valid row in another relation.
What subtypes store:
Unique attributes e.g if a supertype is employee subtypes could be cook,waitress bar man etc
Specialization Hierachy
Shows the arrangment and relationships between entity supertypes and subtypes.
Subtype Discriminator
The attribute in the supertype entity that detirmines which subtype the supertype is related to. E.g Employee type
Overlapping subtypes
Contain nonunique subsets of the supertype entity each instance appearing in more than one subtype. e.g tech an employee can also be a student.
Partial Completeness
Not every supertype occurance is a member of a subtype.
Total Completeness
Every supertype occurance must be part of at least one subtype.
Entity Cluster
a “virtual” entity type used to represent multiple entities and relationships in a erd. Simplifies erd and makes more readable.
Surrogate PK
A Pk created by designer to simplify figuring out entities. Used when there is no natural suitable PK , when it is composite or too long to use.
Fan Trap
Most common design trap. Happens when you have 1 entity in 2 1:M relationships and there is an association that is not expressed in the model. Doesn’t show relationship properly.
Normalization
The process of evaluating and correcting table structures to minimize data redundancy and in turn reducing anomalies.
1NF
Table format, no repeating groups, Pk identified, attributes dependent to PK still has partial dependencies.
2NF
1NF and with no partial dependencies still might have transitive dependencies.
Partial Dependancy
When an attribute is functionally dependant on only one part of a composite primary key. Associated with 1NF.