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

update one table with another with a where clause

Status
Not open for further replies.

rust

Programmer
Jan 27, 2003
34
US
Hi All,

using ACCESS 2000 what I want to do is:

UPDATE A SET
A.gACID = (Select G.actionID from G
where A.PID = G.PID
and not G.Flg = true);

Of course I'm using ACCESS so I need to do something like

UPDATE A inner join G on
A.PID = G.PID
where not G.Flg = true

But it wont accept the where clause - But I need the where clause cause there may be many with the G.Flg = True but only one with the G.Flg = False

Thanks for any help


 
Thanks for replying I actually did get it to work
Have a deadline in an hour so I rushed a little THE SET GOES BEFORE THE WHERE


UPDATE A INNER JOIN G ON G.PID=A.PID SET A.GID = G.myID
WHERE Not G.Flg =True;
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top