This example shows how to use the Open Query File (OPNQRYF) command many times in a program.
You can use the OPNQRYF command more than once in a high-level language program. For example, assume you want to prompt the user for some selection values, then display one or more pages of records. At the end of the first request for records, the user might want to specify other selection values and display those records. This can be done by follow these steps: