1.3.2 Databases Flashcards
What is a relational database?
A database that recognises the difference between entities, using a different table for each
What is an entity?
An item about which information is stored
What is a flat file database?
A database that consists of a single file, usualy one entity
What is a primary key?
A unique identifier given to each record in a table
What is a foreign key?
An attribute that links two tables together
What is a secondary key?
An index other than the primary key used to search and sort through a database with more convenience and speed
What is meant by capturing data?
The process of getting information to be stored in a database
What is meant by selecting data?
The process of removing excess information to extract only the data required
What is meant by managing data?
Manipulating information collected in any way
What is the most common language used to manipulate information in databases?
Structured Query Language (SQL)
What is a one-to-one entity relationship?
Each table can only be linked to one other table
What is a one-to-many entity relationship?
One table can be associated with many other tables
What is a many-to-many entity relationship?
One entity can be associated with many other entities and the same applies for the other
How can a many-to-many relationship be created?
Creating a third table
Using two one to many relationships to third table
What is normalisation?
Creating the best possible design for a relational database
Give 4 things normalisation tries to accomplish.
No redundancy (unnecessary duplicates)
Consistent data throughout linked data
Records can be added/removed without issues
Complex queries can be carried out
How is first normal form achieved?
No attribute can contain more than a single value
How is second normal form achieved?
In first normal form
No partial dependencies
How is third normal form achieved?
In second normal form
No non-key dependencies
What is a partial dependency?
When an attribute depends on part of the primary key
What is a non-key dependency?
When an attribute depends on the value of the primary key and nothing else
What is indexing?
Method that stores the position of each record when ordered by a certain attribute