MIDRANGE dot COM Mailing List Archive



Home » MIDRANGE-L » June 2014

Re: sql file update: pull data from another file



fixed

Joel

I can't tell where each field is coming from - chs# in the first subselect - is that in client or in c1?

So if you can resubmit with all the fields qualified, it would help us to help you.

Regards
Vern

On 6/13/2014 4:19 PM, Stone, Joel wrote:
Is there a simpler method to update one file with data from another using a foreign key? Maybe with a join or exists ??

This works but seems a bit unintuitive.

update jstone/client
set AMNGRNM = (select newgav# from jstone/c1 where ACLNMBR = chs#)
where ACLNMBR = (select chs# from jstone/c1 where ACLNMBR = chs#)

Thanks!



______________________________________________________________________
This outbound email has been scanned for all viruses by the MessageLabs Skyscan service.
For more information please visit http://www.symanteccloud.com
______________________________________________________________________






Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2014 by MIDRANGE dot COM and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available here. If you have questions about this, please contact