The following examples are not coding samples, rather, they demonstrate
how to construct the input parameter list for a number of requests.
Example 1: Add group FINANCE with some BASE segment fields
and an OMVS segment.
Function code = ADMN_ADD_GROUP
Note: For fields which take quoted
data (for example, installation data), the quotes must be included
as part of the data.
* First, define the request header
HEADER DS 0H
DC AL1(7) Length of group
DC CL8'FINANCE' Group name
DC AL1(0) Reserved byte
DC AL2(0) Not used on input
DC AL2(2) Number of segments (BASE+OMVS)
* First segment entry - BASE
BSEG DC CL8'BASE' BASE segment entry
DC CL1'Y' Flag byte - Y - create segment
DC AL2(4) Field count - 4
* First BASE segment field entry
BFLD1 DC CL8'DATA' Data field
DC CL1'Y' Flag byte - Y - create field
DC AL2(20) Length of field data
DC CL20'''FINANCE DEPARTMENT''' Field data
* Second BASE segment field entry
BFLD2 DC CL8'OWNER' Owner field
DC CL1'Y' Flag byte - Y - create field
DC AL2(4) Length of field data
DC CL4'CORP' Field data
* Third BASE segment field entry
BFLD3 DC CL8'SUPGROUP' Superior group field
DC CL1'Y' Flag byte - Y - create field
DC AL2(4) Length of field data
DC CL4'CORP' Field data
* Fourth BASE segment field entry
BFLD4 DC CL8'UNIVERSL' Universal field
DC CL1'Y' Flag byte - Y - boolean value
DC AL2(0) Length 0 - no data for booleans
* Second segment entry - OMVS
OSEG DC CL8'OMVS' OMVS segment entry
DC CL1'Y' Flag byte - Y - create segment
DC AL2(1) Field count - 1
* First OMVS segment field entry
OFLD1 DC CL8'GID' GID field
DC CL1'Y' Flag byte - Y - create field
DC AL2(2) Length of field data
DC CL2'46' Field data
Example 2: This is the same as example 1, but is shown in
"rows", where a single line represents the request header, and individual
segment and field entries. This convention will be used from this
point on.
Function code = ADMN_ADD_GROUP
HEADER DC AL1(7),CL8'FINANCE',AL1(0),AL2(0),AL2(2)
BSEG DC CL8'BASE',CL1'Y',AL2(4)
BFLD1 DC CL8'DATA',CL1'Y',AL2(20),CL20'''FINANCE DEPARTMENT'''
BFLD2 DC CL8'OWNER',CL1'Y',AL2(4),CL4'CORP'
BFLD3 DC CL8'SUPGROUP',CL1'Y',AL2(4),CL4'CORP'
BFLD4 DC CL8'UNIVERSL',CL1'Y',AL2(0)
OSEG DC CL8'OMVS',CL1'Y',AL2(1)
OFLD1 DC CL8'GID',CL1'Y',AL2(2),CL2'46'
Example 3: Alter group FINANCE to remove the OMVS segment
and add a DFP segment.
Function code = ADMN_ALT_GROUP
HEADER DC AL1(7),CL8'FINANCE',AL1(0),AL2(0),AL2(2)
OSEG DC CL8'OMVS',CL1'N',AL2(0)
DSEG DC CL8'DFP',CL1'Y',AL2(2)
DFLD1 DC CL8'DATAAPPL',CL1'Y',AL2(5),CL5'APPL1'
DFLD2 DC CL8'DATACLAS',CL1'Y',AL2(6),CL6'CLASS1'
Example 4: List group FINANCE, showing the BASE, OMVS, and
DFP segments.
Function code = ADMN_LST_GROUP
HEADER DC AL1(7),CL8'FINANCE',AL1(0),AL2(0),AL2(3)
BSEG DC CL8'BASE',CL1'Y',AL2(0)
OSEG DC CL8'OMVS',CL1'Y',AL2(0)
DSEG DC CL8'DFP',CL1'Y',AL2(0)
Example 5: Delete the FINANCE group.
Function code = ADMN_DEL_GROUP
HEADER DC AL1(7),CL8'FINANCE',AL1(0),AL2(0),AL2(0)