History of records - in Table

O

Olivier B

Hi everyone !

I would like to build a database that could keep original version of each
line even if I want to modify something via Form.

Here is a table example :
Recipe | Version| Ingredient 1 | ingredient 2 | and so on.
Pasta | 1 | cheese | ham
Pasta | 2 | tomato | peperoni
Pizza | 1 | pineapple | beef
drink | 1 | vodka | lemon

For each change I would like to do, to this table (via a form + query ?),
Access add another record with the modifications and add a version numper of
the recipe

Could you tell me how to build such a table? (Table + form + query that
would update the Table)

Thanks.
 
D

Damon Heron

Sounds like you need three tables, assuming the ingredients can be 1 to many
for each version.

tblRecipes
RID -autonumber PK
RecipeName - text

tblVersions
VID -autonumber PK
RID - number FK
details - memo

tblIngredients
IngredID - autonumber PK
IngredName - text

The table Recipes has a one to many relationship with tblVersions
Create a form Versions, and have a list box with the source tblIngredients.
Multiselect property. See help for making selections from a multiselect
listbox. The selections would go into the details memo field, along with
any text you wanted to enter.

Damon
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top