|
发表于 2014-6-18 23:43:17
|
显示全部楼层
I have a quick look. Have you designed the tables?
The idea is to design the tables first. You should have several tables.
For example:
Table: Customer
Customer ID(pk), name, address,email, CC
Table: Meal
Meal ID,(pk) name, price, description
Table: Delivery
Delivery Method(PK), Price
Table: Order
Cusomter ID(FK),Meal ID(FK), quantity, Date, Delivery Method(FK)
Now, when you want to do any queries, just join the tables together according to the primary keys. For example, you could creat a view(quiey) called Delivery Cost by joining table Delivery and Order.
Well, you could have other structures for different tables. I did not read your assignment in details. It is just the idea about how to do that. |
|