Spoke&Co
Two shops.
One memory.
SouthCap for Spoke&Co · Database and app design · LLSMF2901 · Group DB9 · 7 December 2026
Three problems, one cause: the shops share nothing.
Two apps, one database.
Staff app · the two shops
Orders
Repairs
Rentals
Stock and transfers
Suppliers
Customer app
Order online
Book a bike
Follow a repair
One Oracle database
28
tables
60 foreign keys
96 checks
iStar: every dependency goes through the website.
Strategic Dependency
1
Strategic Rationale · Website
2
Relational model
Relational model
28 tables, one colour per family.
Zoom 1 / 2 · P1
One catalogue, one stock table.
PRIMARY KEY (STORE_ID, ITEM_ID)
Zoom 2 / 2 · P2
An order, its lines, its delivery.
CHECK (QTY_RESERVED <= QTY_AVAILABLE)
Rules in the database
The database refuses what the business forbids.
96  CHECK constraints
1  compound trigger
no bike booked twice
11  PL/SQL packages
Three core processes, filmed in the app.
Stock between the shops, and from the suppliers.
What the course asks, what we built.
Staff app · the course asks for at least 15 of each
17  queries
course: 15
15  forms
course: 15
15  master-details
course: 15
27  reports
course: 15
Form
Change one row.
Report
List the rows, search, sort.
Master-detail
Click a supplier: below, only its orders.
↓  SUPPLIER_ID  the foreign key
Three queries behind the screens.
Who did what.
R does the work   A answers for it   C consulted   I informed
From model to running system
Questions?
P1 one stock · P2 reserved at order · P3 status online
0:00
1 / 10