Hi,Please give me complete code with this logic.
The question is how to read the records from a file with
load an array of size with error condition?
(The logic is
Z-Add 0 IDX
*LOVAL SETLL FILE
READ FILE 99
*IN9 DOWEQ *OFF
IDX ANDLT 99
ADD 1 IDX
MOVE FIELD ARR,IDX
READ FILE 99
ENDDO)please give me complete code with
explanation?
Answer / indraneel
Z-Add 0 IDX --- Initialize a array index field to 0
*LOVAL SETLL FILE -- repostion pointer to a file.
READ FILE 99 -- read file (EoF indicator is *in99)
*IN9 DOWEQ *OFF -- read FILE till EoF not reached
IDX ANDLT 99 -- and array index is less than 99
ADD 1 IDX -- add one to index
MOVE FIELD ARR,IDX -- moved data from FILE (field)
to array ARR(1)..
READ FILE 99
This code is reading records from a file and moving the
FIELD data to a array..
Is This Answer Correct ? | 1 Yes | 0 No |
this is rpg3 code W0RTN IFEQ @CN,002 what is the means @CN,002
What is the difference between inner join @ outer join
I want my simple Green screen should refersh every 1 min ,How can I do it..? Please share the logic
What is the purpose of record level identifier?
I have two sessions S1 & S2 under this 3 jobs(say j1,j2,j3 under session S1) And 2 jobs(Say j4, j5 Under session S2)is running. How many QTEMP & how many LDA will create for the same.
please guys help me,I need to write a program that shows more than one way to display a subfile. Both views are of the same file but sorted differently and show different fields of the same file when the user presses a function key. send me code
Mr.Sidc sirfor my question{how to convert date format from one format to another i think in CL/400 its CVTDAT,Please tell in RPG/400 sir not in RPGILE} you have answered using MOVE opcode,can you illustrate me with a small example sir very kind of you.
can i use UPDDTA command in rpg program in which contains a file
i 'm new to as/400.in an interview i was asked this question.give a practical example for passing information or data through local data area. I know only that data area is an object used to store tiny bits of data or it can store one value at a time and it is used to store frequently changing values or datas.thats all i know about data area can any one tell me how local data area and user defined data area are used to pass data between jobs with a example or coding.thanks in advance.
Can anybody tell me that why we use option(*nodebugio)in H- Spec?
how do u find whether a record is locked or not??/
Q1.How to read the Array? Q2.How to copy the content of one Array to another Array?