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 TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Update Query - Help 2

Status
Not open for further replies.

firefry

Technical User
Jan 27, 2005
5
US
I am trying to build an Update query but cannot get it to work no matter what I try. I have two tables, tblWFA & tblAdd. They are joined on the field tblWFA.SprLastName & tblAdd.Supervisor. I want to update the Supervisor field in tblAdd with the SprLastName field in tblWFA when tblAdd.Tech=[cboTech.Value]

Can anyone please help?
Thanks in advance.
 
you said you have a link between the two tables, which is the fields you are using to update the other with.

I am assuming that is why it is not working. if you are linking the two tables with information that is not the same, thn it will not work, and you will not have any records to update.

Do you have any other fields within either table that is the ID reference....

Once you change the linking fields then it should work. I hope i have read it correctly, or have you written it incorrectly... And i am missing your point.
 
Your problkem is not do-able in the terms you have described it.

How do you know which record in tblwfa is to be used to update tblAdd?
You say that you are setting one value to be equal to another but the values must already be the same for the record to meet join rules.
If thet are not equal then the records will not be joined on these two fields, so which record to pick?

You need to base the join on two different fields.
 
THANKS!

I chnaged fields where the two tables were joined & it worked like a charm. Thanks for your time!

Fry
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top