Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Updating joined fields with refferencial integrity 1

Status
Not open for further replies.

ovs8

Technical User
Mar 15, 2004
63
0
0
US
Hello,

I have a form which combines 2 fields Organization and Org.Branch that come from separate tables joined with referrential integrity one-to-many.

In this form I'm trying to insert a new Organization and its Branches. I can enter Organization but when I proceed to enter the Branch it doesn't let me saying that join key of one of the tables is not in the record set.

How can I solve this? Is there a way to require or refresh both tables' records after I enter Organization?

Thank you,
oleg
 
How are ya ovs8 . . .

Sounds like you your recordsource is a query/SQL including both tables.
[ol][li]Open the form in design view.[/li]
[li]Open the properties window and click the [blue]Data Tab[/blue].[/li]
[li]Put the cursor on the RecordSource property line and click the three elipses
Elipse3.BMP
just to the right.[/li]
[li]Work you way till you get to query design view.[/li]
[li]Drag/drop the missing join field to the field row.[/li]
[li]Close query design.[/li]
[li]Hit the tab key once and save the form.[/li][/ol]

Calvin.gif
See Ya! . . . . . .
 
A common way to deal with one-to-many relationship is to play with a mainform (based on master table) and a linked subform (based on child table)

Hope This Helps, PH.
Want to get great answers to your Tek-Tips questions? Have a look at FAQ219-2884 or FAQ181-2886
 
Actually, I hoping that there's some SQL code for After Update event and a Requery or something like that.

I tried the SQL code but my form does not refreshes.

oleg
 
ovs8 . . .

Did you try my post?
ovs8 said:
[blue]Actually, I hoping that there's some SQL code for After Update event and a Requery or something like that.[/blue]
This appears to make your post origination [blue]Null & void![/blue]

Calvin.gif
See Ya! . . . . . .
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top