Year 10TechnologiesSupport
Use the three tables from the fictional bushcare group's database. Show the rows you used when you work out a query result.
Read the information
Fictional bushcare volunteer database
- [1]
A bushcare group records which volunteers work at which sites. Each table stores one kind of thing (an entity). All names and data are invented.
- [2]
Table Volunteer: VolID | FirstName | JoinYear
- [3]
V01 | Mia | 2023 ; V02 | Tom | 2024 ; V03 | Aisha | 2022 ; V04 | Lachlan | 2025
- [4]
Table Site: SiteID | SiteName | Habitat
- [5]
S1 | Creek Bend | creek bank ; S2 | Banksia Ridge | heath ; S3 | Wattle Gully | woodland
- [6]
Table Shift: ShiftID | VolID | SiteID | ShiftDate | Hours
- [7]
1 | V01 | S1 | 2026-03-07 | 3
- [8]
2 | V02 | S1 | 2026-03-07 | 2
- [9]
3 | V01 | S2 | 2026-03-14 | 4
- [10]
4 | V03 | S3 | 2026-03-14 | 3
- [11]
5 | V03 | S1 | 2026-03-21 | 2
- [12]
6 | V02 | S2 | 2026-03-21 | 3
- [13]
7 | V01 | S1 | 2026-03-28 | 2
AKeys and links
A primary key is unique in its table. A foreign key points to another table's primary key.
- 1.
What is the primary key of the Volunteer table?
(1 mark)- VolID
- FirstName
- JoinYear
- 2.
Which field in the Shift table is a foreign key that links to the Site table?
(1 mark)- SiteID
- ShiftID
- Hours
- ShiftDate
- 3.
One volunteer can appear in many rows of the Shift table.
(1 mark)- True
- False
BLook it up
Follow the IDs from one table to another.
- 4.
How many shifts were at site S1? List their ShiftIDs.
(1 mark) - 5.
Shift 4 has VolID V03 and SiteID S3. Who worked shift 4, and what is the site's name?
(2 marks) - 6.
Find all of Mia's (V01) shifts and add up her hours.
(2 marks) - 7.
Which volunteer has no shifts in the Shift table?
(1 mark)