|
Thank you, Peter, Paul and Mike. That's works fine. Mike, there is only onw record per NANUM in second file. --- Peter Colpaert <Peter.Colpaert@honda-eu.com> escribió: > > What if you try this: > > UPDATE FILE1 SET FIELD1='X' WHERE NANUM IN (SELECT NANUM FROM > FILE2 WHERE > FIELD2='Z') > > (IN being the operative word here) > > HTH, > > Peter Colpaert > Application Developer > > Honda Europe NV > Langerbruggestraat 104 > B-9000 GENT > Peter.Colpaert@honda-eu.com > Tel: +32 9 2501 334 > Fax: +32 9 2501 231 > ---------- > He's DEAD, Jim. You grab his tricorder, I'll get his wallet. > ---------- > > > > > Oscar Barberá <barberao@yahoo.es>@midrange.com on 12/03/2002 > 12:04:14 > > Please respond to rpg400-l@midrange.com > > Sent by: rpg400-l-admin@midrange.com > > > To: rpg400-l@midrange.com > cc: > > Subject: Re: SQL question > > > Yes, this is what I did, but i get the next message: The > result > of SELECT is more than one row. > > --- Mike.Collins@syan.co.uk escribió: > > > You need to use a subselect: > > > > UPDATE FILE1 SET FIELD1='X' WHERE NANUM = (SELECT NANUM FROM > > FILE2 WHERE > > FIELD2='Z') > > > > > > > > _______________________________________________ > This is the RPG programming on the AS400 / iSeries (RPG400-L) > mailing list > To post a message email: RPG400-L@midrange.com > To subscribe, unsubscribe, or change list options, > visit: http://lists.midrange.com/cgi-bin/listinfo/rpg400-l > or email: RPG400-L-request@midrange.com > Before posting, please take a moment to review the archives > at http://archive.midrange.com/rpg400-l. > _______________________________________________________________ Do You Yahoo!? Yahoo! Messenger Comunicación instantánea gratis con tu gente. http://messenger.yahoo.es
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2024 by midrange.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 on our policy page. If you have questions about this, please contact [javascript protected email address].
Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.