|
In other words, you want to code an "array data structure", right? The syntax for that is:
D FXQS DS qualified DIM(10) D WQTYN 15S 0
and subfields of the DS can then be referred to like "FXQS(X).WQTYN". But such functionality is new to V5R2. An "array data structure" is sort of like a "multiple-occurrence data structure", but the index must be explicitly coded, and the DS must be a qualified DS.
BTW, another of the V5R2 changes is that you can define a subfield of a qualified data structure with keyword LIKEDS. That is, subfields themselves can also be data structures or even array data structures! Coding nested array data structures within array data structures gives you the ability to code something that looks just like multi-dimensional arrays.
typedef struct _MyStruct { int field1; char field2; } MyStruct;
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].
Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.