Using groups in a JES2 system

In JES2 systems, you can group sysout data sets together by coding:
   //name  OUTPUT GROUPID=output-group  

Sysout data sets in the same group are processed together in the same location and time.

Subgroups

You can always group sysout data sets with similar processing characteristics. But, you cannot group sysout data sets with different output classes, destinations, processing modes (PRMODE), writer names, or groupids. If you use GROUPID to group dissimilar data set, the system breaks down the group into subgroups of sysout data sets with identical classes, destinations, processing modes, writer names, and groupids.

Demand setup groups

The installation controls whether a group can contain sysout data sets with different printer setup requirements, such as forms. Such groups are called demand setup groups. If demand setup grouping is not permitted, data sets with different setup requirements are placed in different subgroups.

Example
//TEST1  JOB     MSGCLASS=B
//OUT1   OUTPUT  GROUPID=GRP10,UCS=PN,DEST=RT6,DEFAULT=YES
//STEP1  EXEC    PGM=REPORT
//RP1    DD      SYSOUT=A
//RP2    DD      SYSOUT=B
//RP3    DD      SYSOUT=A  

In this example, two subgroups are created for the three sysout data sets because of the different output classes. One subgroup contains data sets RP1 and RP3; the other contains RP2.