Answer it
P1 a3 library keys
3 marksYou mark it yourself against the marking points
Identify the keys in this small school library database. It has two tables.
| Table | Fields |
|---|---|
| Book | book_id, title, author, year_published |
| Loan | loan_id, book_id, student_name, due_date, returned |
Every loan gets a new loan_id. The same book can be borrowed many times, so one book_id can appear in many Loan records.
(a) Identify the primary key of the Loan table. [1]
(b) Identify the foreign key in the Loan table, and explain how it links a loan to the book that was borrowed. [2]
[3]