How to read data from Nth member of a physical file containing
some X number of members in it?
"Provided member names are unknown"
Answers were Sorted based on User's Feedback
Answer / sandey243
Way:1
We can execute DSPFD with *OUTFILE option, using QCMDEXC in
RPGLE program then we can read the outfile to get the name
of the file, then after we can read the file.
Way2:
Make the file to have all members available i.e.,
EXTMBR(*ALL). Then move *HIVAL to RRN and do a SETGT on the
file... this will take the control to the bottom of the
first member...then READ will give you first record of the
Second member...... This way we can go to the member....
(This method I tried and succeeded)...
| Is This Answer Correct ? | 10 Yes | 1 No |
Answer / zavith ahamed
to declare f spec extmbr(*all) to read the data from file
| Is This Answer Correct ? | 0 Yes | 1 No |
Answer / sakshi bansal
I tthink we can use OVRDBF command in Cl and call RPG through it.
| Is This Answer Correct ? | 0 Yes | 5 No |
what is the difference between the procedure and module in ILERPG?
Difference between creating a report using Printer file and WRKQRY(Query Report) ?
this is rpg3 code W0RTN IFEQ @CN,002 what is the means @CN,002
how can i retrieve the field name from display file at run time? Devendra Singh Tomar
A rpg or clp command to find if the file field is defined as a character or numeric field.
what are the array operations?
How many program bind in one module....
When will DUMP & DEBUG be ignored?
can i use UPDDTA command in rpg program in which contains a file
I have some doubts on subfile----------- -----I wrote a prog on subfile to display the records. Every thing is clear but i defined a field called "opt" as input field in subfile record format from that input field i wish to enter into new screen called "EDIT" which i created it as a separate RCD in display file. i gave opt as 2 for edit just like in WRKMBRPDM screen please telll me the code and how can i code for it in RPG.
what are the types of identifers
If my rpg program has a date field, what extra care I have to take while compiling that rpg program? If the file is keyed and I have declared the file as well as key list properly in my program. Still am getting an error message like "chain/reade operation is not allowed" what may be the case?