The database supports ACID transactions. ACID stands for Atomicity, Consistency, Isolation and Durability.
Give one way that durability can be achieved for a completed transaction.
Did this page help you?
The database supports ACID transactions. ACID stands for Atomicity, Consistency, Isolation and Durability.
Give one way that durability can be achieved for a completed transaction.
How did you do?
Did this page help you?
Give one disadvantage of using record locking.
How did you do?
Did this page help you?
OCR Insurance uses a computer system to calculate the price that customers pay for car insurance.
Customers’ details are stored in the flat file database table Customer
Describe one problem that would arise with the flat file database structure if a customer wanted to insure more than one car at the same time.
How did you do?
Did this page help you?
Details of all users that have accessed the robot are stored in a database table called TblAccessLog
. This table stores the username and user type of each user. When a user accesses the robot, the current date is added to the DateAccessed
field for that user.
A selection of the data from this table is shown here. Username
is the key field.
Username | UserType | DateAccessed |
---|---|---|
Mrphy003 | User | 08/05/21, 07/06/21, 08/06/21 |
Lwis076 | Admin | 17/04/21, 19/07/21 |
Bbby412 | NotNeeded | 01/06/21, 02/07/21, 14/07/21 |
Write an SQL statement to delete all records from the table TblAccessLog
for users who have a UserType of "NotNeeded".
How did you do?
Did this page help you?
State what is meant by the term ‘primary key’.
How did you do?
Did this page help you?
Customers’ details are stored in the flat file database table Customer
. An extract of the table is shown below.
Identify the foreign key used in the database and the table name where this is a foreign key.
How did you do?
Did this page help you?
OCR Insurance uses a computer system to calculate the price that customers pay for car insurance.
Customers’ details are stored in the flat file database table Customer
. An extract of the table is shown below.
CustomerID | Surname | Title | Phone | CarReg |
---|---|---|---|---|
JJ178 | James | Mr | (0121) 343223 | DY51 KKY |
HG876 | Habbick | Miss | (01782) 659234 | PG62 CRG |
EV343 | Elise | Mrs | (07834) 123998 | HN59 GFR |
PG127 | Pleston | Mr | (07432) 234543 | JB67 DSF |
State what is meant by the term ‘primary key’, identifying the primary key in the table above.
How did you do?
Did this page help you?
A hotel stores data about rooms, customers and bookings in a database. Each customer can book multiple rooms and each room can be booked multiple times
Define what is meant by the term ‘foreign key’, giving one example of where a foreign key would be used in the hotel booking database.
How did you do?
Did this page help you?
Explain how record locking can be used to ensure that the ACID principle of isolation is achieved when carrying out multiple transactions.
How did you do?
Did this page help you?
State two requirements for a database to be in First Normal Form (1NF).
How did you do?
Did this page help you?
Details of all users that have accessed the robot are stored in a database table called TblAccessLog
. This table stores the username and user type of each user. When a user accesses the robot, the current date is added to the DateAccessed
field for that user.
A selection of the data from this table is shown here. Username is the key field.
Username | UserType | DateAccessed |
---|---|---|
Mrphy003 | User | 08/05/21, 07/06/21, 08/06/21 |
Lwis076 | Admin | 17/04/21, 19/07/21 |
Bbby412 | NotNeeded | 01/06/21, 02/07/21, 14/07/21 |
Explain why the structure of TblAccessLog
means that this database is not in First Normal Form (1NF).
How did you do?
Did this page help you?
Customers’ details are stored in the flat file database table Customer
. An extract of the table is shown below.
The Adverts
field indicates if customers will be shown adverts. true
indicates that customers will be shown adverts, and false
indicates that adverts are not shown.
Write Structured Query Language (SQL) to return the Username
and FirstName
fields for all customers who see adverts.
How did you do?
Did this page help you?
When new customers join the streaming service, their name, email address and contact details are captured so that they can be entered into the database.
Identify one method of capturing a new customer’s personal data, describing why this method is suitable.
How did you do?
Did this page help you?
Sometimes a company may need to move or backup its data they hold about customers.
Identify two methods of exchanging data with other computer systems
How did you do?
Did this page help you?
A database supports ACID transactions. ACID stands for Atomicity, Consistency, Isolation and Durability
Describe what is meant by a transaction being durable.
How did you do?
Did this page help you?
OCR Insurance uses a computer system to calculate the price that customers pay for car insurance.
Customers’ details are stored in the flat file database table Customer
. An extract of the table is shown below.
CustomerID | Surname | Title | Phone | CarReg |
---|---|---|---|---|
JJ178 | James | Mr | (0121) 343223 | DY51 KKY |
HG876 | Habbick | Miss | (01782) 659234 | PG62 CRG |
EV343 | Elise | Mrs | (07834) 123998 | HN59 GFR |
PG127 | Pleston | Mr | (07432) 234543 | JB67 DSF |
Write the SQL statement that would show only the CustomerID
and Surname
fields for customers with the Title “Miss
” or “Mrs
”.
How did you do?
Did this page help you?
OCR Insurance uses a computer system to calculate the price that customers pay for car insurance.
Customers’ details are stored in the flat file database table Customer
. An extract of the table is shown below.
CustomerID | Surname | Title | Phone | CarReg |
---|---|---|---|---|
JJ178 | James | Mr | (0121) 343223 | DY51 KKY |
HG876 | Habbick | Miss | (01782) 659234 | PG62 CRG |
EV343 | Elise | Mrs | (07834) 123998 | HN59 GFR |
PG127 | Pleston | Mr | (07432) 234543 | JB67 DSF |
Describe how the flat file database structure could be altered to efficiently allow each customer to insure multiple cars at the same time. (You may assume each car is insured to only one customer.)
How did you do?
Did this page help you?
A hotel uses a computer system to keep track of room bookings. The hotel staff are able to query a database to discover which rooms are booked or which rooms are free.
The hotel stores data about rooms, customers and bookings in a database. Each customer can book multiple rooms and each room can be booked multiple times.
Draw an Entity Relationship Diagram for this database.
How did you do?
Did this page help you?
Explain what is meant by the term ‘referential integrity’ and how this could potentially be broken.
How did you do?
Did this page help you?