105 pts.
 operation code-occur
In what condition we have to use occur?what is the use of occur(Set/Get Occurrence of a Data Structure )?

Software/Hardware used:
ASKED: October 23, 2008  7:22 AM
UPDATED: October 24, 2008  2:22 PM

Answer Wiki:
Occur is used with a multiple occuring datastructure Kind of like an array D MyDS DS Occurs(10) D Myfield1 10A D Myfield2 6 0 Positioning to an occurance or finding out which occurance you are positioned to is the OCCUR 5 OCCUR MyDS <-- positions to the 5th "record/occurance/set" OCCUR MyDS P <- P contains the position (5) that you are at
Last Wiki Answer Submitted:  October 23, 2008  2:13 pm  by  philpl1jb   44,190 pts.
All Answer Wiki Contributors:  philpl1jb   44,190 pts.
To see all answers submitted to the Answer Wiki: View Answer History.


Discuss This Question:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _


 

You can also use a data structure array, instead of the OCCUR operation or the %Occur function. Functionally, a multiple occurrence data structure is essentially an array of data structures, so defining and manipulating these as an array tends to be a cleaner and easier syntax, particularly to those used to other languages.

Here is an informative article about the subject.
http://www.mcpressonline.com/programming/rpg/exploring-v5r2s-data-structure-arrays.html

 4,275 pts.