what is the necessary command needed before OPNQRYF and why?
Answer Posted / sumit gupta
Hi guddu............
OVRDBF is not mandatory before doing OPNQRYF. OVRDBF is
only used to share the open data path within the calling
program(i.e we can use the selected records from OPNQRYF in
further program whose call is being made after
OVRDBF+OPNQRYF).
But is we dont use the OVRDBF command then open data path
will not be shared and if we done the RCVF on that file
after OPNQRYF(WITHOUT OVRDBF) then the selected records
from OPNQRYF will not be used and this RCVF will process
all the records from that file.
OVRDBF command is used just to share the open data path (By
specifying SHARE(*YES).
We we want to use the selected records from the OPNQRYF in
our further programs which call after this CL then we can
use CPYFRMQRYF command to copy all the selected records
from this OPNQRYF and then RCVF on this new file(which has
got generated by CPYFRMQRYF).
| Is This Answer Correct ? | 11 Yes | 2 No |
Post New Answer View All Answers
write an RPG program to calculate the marks of 5 students (A,B, C, D, E)in 3 different subjects (eng, math, sci) an display on the screen
How to call one program from another program in RPG? please help me with the code
what is data area and how it is used in rpg program ?
how do I play {insert rpg system here}?
How many program bind in one module....
Explain mdt?
1. What is bound-by-call and bound-by-reference? 2. Where and why is *Nomain used? 3. What are the difficulties faced by programmers when using service programs? 4. Explain the different ways of parsing and compiling XML in iSeries.
how do you use commitment control in rpg?
how do I declare a minor?
How Chain operation copies the record's data to the input buffer for the program?
what is file information data structure?
what happens when sflsiz = sflpag? What are the advantages and disadvantages?
How would display prime numbers using CL program?
how do I preserve and clean the array?
Assume 2 users are using the same file and first user updates some record in the file. Will the 2nd user will be able to see the updated record or not?