× 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.



I recently "discovered" OPNQRYF and I'm trying to figure out how (or if) it I 
can use it in my current programming project.

Most of the information I need is in a detail file, however, two very important 
pieces of information (the transaction date and the transaction type) are only 
in a header file.  I was going to create a logical file that joined the two 
physical files and then let the RPG program determine which records to include 
in the report, based on parameters entered by the user.

I know that I can use OPNQRYF to select the desired records before the RPG 
program starts.  The problem I have is that OPNQRYF will only open a join file 
in input mode (*INP) and what I need is output mode (*OUT).  At least that's 
how I read the IBM manual.

So here's my question, can I use OPNQRYF to select the desired records from the 
physical files and still use the logical join file to access them from my RPG 
program?  If not, do you have any other suggestions of what I could try?  (I'm 
sure that this could be done with SQL, but I know even less about how to do 
that than I do about OPNQRYF.)

Finally, could you suggest a good resource(s) for learning more about OPNQRYF?

Thanks!

Janell Haskins
Programmer/Analyst
Knit-Rite, Inc.
(913) 281-4600, ext. 113



As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:

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.