Forms and Related Tables

  • Thread starter Thread starter Iragalam
  • Start date Start date
I

Iragalam

Background:
I'm playing around with a small database. I have a table for
Actions(Autonumber Key) and a table for Assignees(Autonumber Key). I want
one assignee to be able to get multiple actions.

I want to make a New Action form where I can insert things like Action#,
Title, Description, Assignee Name.

Problem:
I can't figure out how to use Assignee Name instead of Assignee ID in the
form without creating a new Assignee record each time.

1 Assignee to many Actions...any help would be great!
 
You need what is known as a junction table with foreign keys of the Assignee
ID and Actions ID. In it you might want Start - DateTime, End - DateTime,
Remarks - Memo, Etc.
Create a relationship of one-to-many from Actions to junction on the Actions
ID and from Assignee to junction on Assignee ID.
Then use queries for your form/subforms. The form/subform are to be linked
Master/Child on the Assignee ID or Actions ID as appropriate.
If you want to display Actions to Assignees then Actions in the form and
Assignees in the subform. In the subform datasheet have a combo box to
select new assignees.
If you want to display Asignees to Actions then Assignees in the form and
Actions in the subform. In the subform datasheet have a combo box to select
new Actions.
 
Thanks this worked perfectly. For some reason I didn't think this was a
many-to-many relationship.
 

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

Back
Top