I know chain keyword retreive records randomly but how chain
keyword exactly works internally????
Answers were Sorted based on User's Feedback
Answer / drew
CHAIN:
positions current record to correct record based on key
sets HI indicator *ON if position fails and sets %found()
off in free-form code
reads the record fields into the automatic internal buffer
fields
locks the record, if in update mode and "no lock" has not
been added to the command ( chain(n))
| Is This Answer Correct ? | 1 Yes | 0 No |
Answer / sandy
chain op code firstly set the file pointer to BOF(begin of file).then look for key or rrn which is specified in factor 1.
in rpg400 EX:
Factor1 opcode factor2 Key/rrn chain file name/record format name
| Is This Answer Correct ? | 1 Yes | 0 No |
Answer / nkumar
With chain High indicator is defined which will be set on if record is not found. Chain works exactly like SETLL and then READ record. If the record is found it will be read and indicator will be OFF and if record is not found then indicator will be ON.
| Is This Answer Correct ? | 0 Yes | 0 No |
What is the difference between iter and do?
How Chain operation copies the record's data to the input buffer for the program?
How to update physical file in rpgle without using display file?
Can we found a record existance in a file w/o reading the file?
6 Answers Traitsys Technologies,
what is post opcode do
what is *place and *auto keyword in prtf ?plz explain
suppose a job is running for 15 minutes after that it goes to message wait? what are the impact analysis
what is the difference between SETON RT & RETURN?
how to display all the members records in a physical file without using ovrdbf?
how we create binder member for updating service program and where we type this code on command line or in program ? strpgmexp pgmlvl(*current) export symbol (xyz0 endpgmexp. plz explain me this step by step .
I know chain keyword retreive records randomly but how chain keyword exactly works internally????
How to update selected fields from pf without using update opcode. How to read all member in Rpg-3,without using any cl command?