If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. |
|
|
Thread Tools | Display Modes |
#1
|
|||
|
|||
Restaurant Database
Hello All Experts,
I have been after this for quiet some time now :-(. I want to design a database for a Restaurant. As I am a newbie on the learning curve I need a helping hand to guide me thru. I have the following Tables. RI = Referential Integrity, CU = Cascade Update, CD = Cascade Delete 1 to M = One-to-Many Relationship Customer -CustomerID (PK) -other details as name, surname etc. - StaffID (FK) - OrderID (FK) Table - TableID (PK) - TableDetails Staff -StaffID (PK) -StaffName, DateofHire, etc -StaffRoleID (FK) StaffRole -StaffRoleID (PK) -StaffRoleDescription Order - OrderID (PK) - OrderDate - OrderTime - CustomerID(FK) - StaffRoleID(FK) (1 to M ) - MenuItemID (FK) - TableID (FK) OrderMenuItem - OrderMenuItemID (PK) - OrderMenuItemQuantity MenuItem - MenuItemID (PK) - MenuItemDescription - MenuItemPrice - MenuItemQuantity - CategoryID (FK) (1 to M with RI) - OrderID (FK) (1 to M with RI, CU, CD) Categories - CategoryID (PK) - CategoryDescription (eg Starters, Desserts, Cold Drinks etc. etc.) - CustomerID (FK) (1 to M) Payments - PaymentID (PK) - OrderID (FK) (1 to M with RI, CU and CD) - PaymentAmount - PaymentDate - PaymentMethodID (FK) (1 to M) PaymentMethod - PaymentMethodID (PK) - PaymentMethod (eg Credit Card, Cash, Check etc. ) OrderDetails - OrderDetaisID (PK) - OrderID (FK) (1 to M) RI, CU, CD - MenuItemID (FK) (1 to M) - Quantity - UnitPrice - Discount This is how far I have got. Can somebody guide me in restructuring my design. I must have missed several basics. Pardon me for my ignorance. Basically I want to design a Restaurant database where the Customer walks in and places an Order from a Category (subdivided in MenuItems) which is executed by a Staff. After the completion of the order the Bill will be generated. Any help or suggestions would be very much appreciated. Rashid Khan |
Thread Tools | |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Images in a database | Franz | General Discussion | 10 | October 7th, 2004 09:35 AM |
Database Window Gone | DaveB | General Discussion | 2 | July 29th, 2004 12:24 AM |
Database periodically needs rebuild and locks users out | spectrum | General Discussion | 2 | July 13th, 2004 06:24 PM |
You do not have exclusive access... ERROR | Robin | General Discussion | 1 | July 6th, 2004 01:18 AM |