Okay, so time for a more specific question related to my last post:
The db has several tables for different type of sales items:
tbl_FOOD
tbl_BEV
etc.
These tables have fields:
FOOD_ID
BEV_ID
etc.
as the PK and then fields:
FOOD_NAME
BEV_NAME
for a text description of the item.
I also have:
tbl_ITEM_TYPE
which just assigns a value to each type with fields:
ITEM_TYPE_ID
ITEM_TYPE
so for example you have ITEM_TYPE_ID = 1, ITEM_TYPE = Food.
Now I have:
tbl_SALES_ITEM
that I want to incorporate:
ITEM_TYPE and related ID (FOOD_ID, BEV_ID) from the specific table
The FOOD_ID / BEV_ID is used as a FK as SALES_ITEM_ID in tbl_SALES_ITEM.
(ex. In tbl_FOOD, FOOD_ID = 1, FOOD_NAME = Hamburger. So in tbl_SALES_ITEMS I have SALES_ITEM_ID = 1, ITEM_TYPE_ID = 1, SALES_ITEM = 1, This is a Hamburger which has an ITEM_TYPE of FOOD.)
I am doing all this because I want to keep food and beverages in separate tables, but I want users to be able to see a "menu" and sort their view by Item Type (food / bev). My gut wants to do this by throwing all my menu items together in one table and then give that table a separate column labeled ITEMTYPE and then use combo boxes, listboxes and IF...THEN statements in VBA to filter things out for the user to see... BUT, as per my previous posting in this room, I am really, really new to the idea of normalization (by new, I mean about 3 days into hearing the word), and I now think it is better to keep the different TYPES of items in different tables, have a different table for ITEM_TYPES and then relate those 2 tables together to create a sales item. But how?
Sorry if this is rambling and confusing, but my mind is rambling and confused. I would appreciate any help / suggestions.
Thanks in advance.
MR_G
The db has several tables for different type of sales items:
tbl_FOOD
tbl_BEV
etc.
These tables have fields:
FOOD_ID
BEV_ID
etc.
as the PK and then fields:
FOOD_NAME
BEV_NAME
for a text description of the item.
I also have:
tbl_ITEM_TYPE
which just assigns a value to each type with fields:
ITEM_TYPE_ID
ITEM_TYPE
so for example you have ITEM_TYPE_ID = 1, ITEM_TYPE = Food.
Now I have:
tbl_SALES_ITEM
that I want to incorporate:
ITEM_TYPE and related ID (FOOD_ID, BEV_ID) from the specific table
The FOOD_ID / BEV_ID is used as a FK as SALES_ITEM_ID in tbl_SALES_ITEM.
(ex. In tbl_FOOD, FOOD_ID = 1, FOOD_NAME = Hamburger. So in tbl_SALES_ITEMS I have SALES_ITEM_ID = 1, ITEM_TYPE_ID = 1, SALES_ITEM = 1, This is a Hamburger which has an ITEM_TYPE of FOOD.)
I am doing all this because I want to keep food and beverages in separate tables, but I want users to be able to see a "menu" and sort their view by Item Type (food / bev). My gut wants to do this by throwing all my menu items together in one table and then give that table a separate column labeled ITEMTYPE and then use combo boxes, listboxes and IF...THEN statements in VBA to filter things out for the user to see... BUT, as per my previous posting in this room, I am really, really new to the idea of normalization (by new, I mean about 3 days into hearing the word), and I now think it is better to keep the different TYPES of items in different tables, have a different table for ITEM_TYPES and then relate those 2 tables together to create a sales item. But how?
Sorry if this is rambling and confusing, but my mind is rambling and confused. I would appreciate any help / suggestions.
Thanks in advance.
MR_G