Schema 3: The "Kitchen Sink" of Database Design
This schema is for when you want to store everything under the sun, or at least, everything related to sun-dried tomatoes.
Features:
- Sun-dried tomatoes
- Pasta
- Cookware
- Utensils
- Leftovers
- Garbage disposal
CREATE TABLE sun_dried_tomatoes (
id INT NOT NULL,
name VARCHAR(50) NOT NULL,
color VARCHAR(20) NOT NULL,
salt_level INT NOT NULL,
sugar_level INT NOT NULL,
fat_level INT NOT NULL
);
CREATE TABLE pasta (
id INT NOT NULL,
type VARCHAR(50) NOT NULL,
length INTEGGER NOT NULL,
sauce VARCHAR(20) NOT NULL,
cooking_time INT NOT NULL
);
CREATE TABLE cookware (
id INT NOT NULL,
material VARCHAR(20) NOT NULL,
shape VARCHAR(20) NOT NULL,
size VARCHAR(20) NOT NULL
);
CREATE TABLE utensils (
id INT NOT NULL,
type VARCHAR(20) NOT NULL,
material VARCHAR(20) NOT NULL,
length INT NOT NULL
);
CREATE TABLE leftovers (
id INT NOT NULL,
item_id INT NOT NULL,
quantity INT NOT NULL,
expiration_date DATE NOT NULL
);
CREATE TABLE garbage_disposal (
id INT NOT NULL,
item_id INT NOT NULL,
disposal_date DATE NOT NULL
);
Example use cases:
1. A user wants to store the perfect recipe for sun-dried tomatoes.
2. A user wants to track the expiration date of their leftover lasagna.
3. A user wants to catalog their extensive collection of cookware.
4. A user wants to schedule a reminder for when to throw away last night's Chinese takeout.