need help

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

hi all,
im currently doing a list of menu/set of things
Each menu have different things.
And each things have different price.

May i know how to do it?
Please help
 
Hi WeeShawn

Assuming that:
1) there is more than one thing/menu
2) each thing may be on more than one menu

You will need three tables

tblMenu
MenuID (autonumber) Primary Key
MenuName (text) Unique Index

tblThings
ThingID (autonumber) Primary Key
ThingName (text) Unique Index
ThingPrice (currency)

tblMenuDetails
MenuID (number - long) {combined }
ThingID (number - long) {primary key}
ThingQty

In the relationships window for your DB, create a one to many relationship
between tblMenu and tblMenuDetails using the MenuID fields in each of the two
tables

then
create a one to many relationship between tblThings and tblMenuDetails using
the ThingID fields in each of the two tables.

It is VERY important that with the table tblMenuDetails, you have a combined
Primary Key comprised of the two fields MenuID and ThingID.

Hope this helps
 
Back
Top