How to declare the dynamic(run time) array in rpgle?
can you please give example

Answers were Sorted based on User's Feedback



How to declare the dynamic(run time) array in rpgle? can you please give example..

Answer / royal

Dmonth S 5s 0 DIM(5)
DI S 2p 0 inz(1)
c dow i <= 10
c* eval month(i) = i
c month(i) dsply
c eval i = i + 1
c enddo
/FREE
*INLR = *ON ;
/END-FREE


this answer is not correct please give me correct code

Is This Answer Correct ?    3 Yes 2 No

How to declare the dynamic(run time) array in rpgle? can you please give example..

Answer / karthik

Dary1 s dim(5)
Dn s 2p 0 inz(1)
c dow(n<=10)
c ary1(n) dsply
c eval n=n+1
c enddo
c seton lr

Is This Answer Correct ?    3 Yes 5 No

Post New Answer

More RPG400 Interview Questions

how can you display specific subfile page on the screen in unequal subfile?

0 Answers   IBM,


Is it possible to call a subfile using CL. IF yes.. kindly help me out with explanation...?

3 Answers  


1.String operatio such as moving the characters to the variables? 2.what are the building functions for check file longs? 3.which of the following methods will make externally describe file fields available to a program? A: A/copy statement that specifies the library file and member of the field reference file source code B: A data structure definition specification that names the file on the EXTNAME keyword C: A data structure definition specification that names the file on the IMPORT keyword? D: A Definition specification for each desired field with the REFFLD keyword

1 Answers   CSC, CTS,


Why there is invention of RPG if we can do insert update delete in CL through SQL.Why the rise of RPG?

1 Answers   Infogain,


Difference between RESET and CLEAR

1 Answers   TCS,






What is file identifier where we can use?

0 Answers  


How do you proceed in case your active AS400 session has got disconnected suddenly, how can you get back to your session ? Is it possible??

1 Answers  


Can anybody tell me the setps to create .csv file in IFS folder on AS/400. I also need to know how I can send this .csv file to PC in xls sheet.....?

2 Answers  


what is use of sflnxtchg and use of MDT(modify data tag).both r same r not and can we use these on dspf and subfile.

2 Answers  


Difference between creating a report using Printer file and WRKQRY(Query Report) ?

3 Answers  


what is kids-rpg?

0 Answers   IBM,


1.What is referential Integrity? 2.What is Foreign Key? 3.What is Transfer Control? 4.What is Free format?

3 Answers  


Categories