× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



Greetings from sunny Florida.


I have an embedded SQL statement in an RPG /Free program which gets the
value of two fields in one file. The records in this file (VENDORFL00) are
dependent upon the value of a field in a second file (EDIPFCONT1):


// Assemble SQL Statement
QQSQL = 'Select VENDOR, VENDNAME From VENDORFL00 ' + // Select Fields
'Where VENDNAME >= ' + @Tic + @ArgName + @Tic +
'And VENDOR In (Select A.C1VEND From EDIPFCONT1 A Join VENDORFL00 B -
On A.C1VEND = B.VENDOR -
Where A.C1VNDEDI = ' + @Tic + @Yes + @Tic + ') ' + // Select EDI Vendors
From Contact
'Order By VENDNAME ' + For_Read; // Order By Vendor
Name


My requirements have changed and I need to capture the value of a field
(C1USER) in the second file (EDIPFCONT1). I will use these three fields to
load a subfile. Until I solve this, I'm having to chain to the second file
as I load each subfile record to get the User field value. This is most
inefficient. I'm checking that file for the condition, but now I need a
value from it.

How do I compose a Join or Union to get VENDOR and VENDNAME from VENDORFL00
and C1USER from EDIPFCONT1? They are joined by the Vendor Number. I have
tried various combinations without success both in the program and
interactively.

If you can help, please e-mail me directly at RMunday@xxxxxxxxxxxxxx Our
new CEO shut down access to online e-mail so I have been unable to view or
access the Midrange Lists. It hurts to be without this resource.

Thanks,



Robert Munday
Munday Software Consultants
Montgomery, AL
on assignment in Jacksonville, FL
soon to be somewhere else...


As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:
Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

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.