Untitled
unknown
plain_text
a month ago
676 B
5
Indexable
CREATE TABLE Students (
student_id INTEGER PRIMARY KEY,
name TEXT NOT NULL,
email TEXT,
phone TEXT,
join_date TEXT
);
CREATE TABLE MenuItems (
item_id INTEGER PRIMARY KEY,
item_name TEXT NOT NULL,
price REAL NOT NULL,
category TEXT
);
CREATE TABLE Orders (
order_id INTEGER PRIMARY KEY,
student_id INTEGER NOT NULL,
item_id INTEGER NOT NULL,
quantity INTEGER NOT NULL,
order_date TEXT,
amount_paid REAL,
FOREIGN KEY (student_id) REFERENCES Students(student_id),
FOREIGN KEY (item_id) REFERENCES MenuItems(item_id)
);Editor is loading...
Leave a Comment