1.3.2 Databases Flashcards
1.3.2 A)
What is a database
organised collection of data. That allows for easy adding, modifying, deletion and searching of the data.
1.3.2 A)
Inside a database a table is also known as
Inside a table a row is also known as
Inside a table a column is also known as
1) an entity or file
2) a row or tuple
3) a field or attribute
1.3.2 A)
What is the advantages and disadvantages of a flat file
A) simple and quick to set up, do not need a specialised to maintain, good for storing small amount of data
D) When lots of data inputted likely to have repeating data which is inefficient as it takes up unnecessary space, it becomes slow to query and is difficult to maintain.
1.3.2 A)
What is a flat file
single file, with comma separated values (csv)
1.3.2 A)
What is a relational data base
Splits information into multiple tables. links tables with one another using relationships for 1:M , M:M , 1:1.
1.3.2 A)
What is the advantages and disadvantages of a relational data base
A) structured and efficient way to store and retrieve data , reduce redundancy.
D) Expert needed , costs , performance
1.3.2 A)
What is a primary key
A field that has a unique value / a
unique identifier (1) for every record in
that table (1)
1.3.2 A)
What is a foreign key
attribute that links to tables together, foreign key has to be a primary key in another table
1.3.2 A)
What is a composite key
candidate key that consists of two or more attributes that together create a unique identifier. values of comp key must be diff across all records
1.3.2 A)
What is a secondary key
Can also specify one or more secondary keys to be indexed. Helped files be searched quickly and easily (instead of typing a unique id something easy to remember like a last name )
1.3.2 A)
What is indexing
Held for primary keys so it can be easily located quickly. so that sequential searching is not needed.
1.3.2 A)
What is normalisation ? ( in terms of data bases )
Process of coming up with the best possible layout for relational databases.
1.3.2 A)
Properties of normalisation in terms of databases
no redundancy
consistent data in linked tables
easy to add / remove records
1.3.2 C)
What is first normal form
- No Repeating fields/data
- Data is atomic
- Has a primary Key
1.3.2 C)
What is second normal form
- Is in First Normal Form
- Every field is dependent on the
primary key
1.3.2 C)
What is third normal form
does not have a transitive relationship/ A non-key field depends on another non-key field
1.3.2 E)
What is referential integrity
The process that ensures consistency. Ensure that information is not removed if it is required elsewhere in a linked data base. If 2 db are linked cannot detect
Ensuring that changes are consistent
across a database
– if a record is removed all references to
it are removed
– A foreign key value must have a
corresponding Primary key value in
another table
1.3.2 F)
Transaction processing
ensuring that interdependent operations on the system are either all completed successfully or all canceled successfully
Makes sure operation happens.
1.3.2 F)
What acronym can be used for transaction processing
A- Atomicity
C-consistency
I-isolation
D -durability
1.3.2 F)
ACID -Atomicity
Transaction must be procession in it entirety or not at all
1.3.2 F)
ACID -consistency
Transaction must maintain the integrity laws between linked lists
1.3.2 F)
ACID -Isolation
Simultaneous execution of transactions should lead to same result as if it was one after the another.
1.3.2 F)
ACID -Durability
Once a transition has been executed it will remain so regardless of env. such as a power cut.
1.3.2 F)
What is record locking
and what is the use
The process of preventing simulations access to record in a db. Used to prevent inconsistency or a loss of update. while one person edits a record it lock .
1.3.2 F)
What is the con’s record locking
Deadlock - people waiting for access while already looking at a record causing no one moving
1.3.2 F)
What is redundancy
Some info important and cannot be lost.
redundancy is the process of having copies of data in physically diff locations .