z/OS DFSORT Application Programming Guide
Previous topic | Next topic | Contents | Contact z/OS | Library | PDF


OUTFIL

z/OS DFSORT Application Programming Guide
SC23-6878-00

INCLUDE, OMIT, IFTRAIL TRLID=(logexp), IFTHEN WHEN=(logexp), IFTHEN BEGIN=(logexp) and IFTHEN END=(logexp) operands: You can use symbols where you can use fields (p1,m1,f1 and p1,m1 and p2,m2,f2 and p2,m2) and constants (n, +n, -n, C'xx...x', X'yy...yy', Y'yyx...x' and B'bbbbbbbb...bbbbbbbb'). A symbol for p,m,f results in substitution of p,m if symbol,f is specified. A symbol for 'string' always results in substitution of C'string'.
Note: You can use a symbol for Y'DATEx', Y'DATEx'+n or Y'DATEx'-n (where x is 1, 2 or 3) in the INCLUDE, OMIT, TRLID, WHEN, BEGIN or END operand, but you cannot use symbol+n or symbol-n to substitute Y'DATEn'+n or Y'DATEn'-n in the INCLUDE, OMIT, TRLID, WHEN, BEGIN or END operand. See the discussion of "INCLUDE and OMIT" for further details.

PARSE operand: You can use symbols where you can use parsed fields (%nn) and constants (C'xx...x' and X'yy...yy').

OUTREC, BUILD, OVERLAY, FINDREP, IFTRAIL TRLUPD, IFTHEN BUILD, IFTHEN OVERLAY, IFTHEN FINDREP and IFTHEN PUSH operands: You can use symbols where you can use output columns (c:), fields (p,m,f and p,m and p), parsed fields (%nn), non-repeated constants (C'xx...x' and X'yy...yy', but not nC'xx...x' or nX'yy...yy'), and decimal constants (+n and -n, but not n). You cannot use symbols for edit patterns ('pattern').

In the JFY and SQZ suboperands, you can use symbols where you can use constants (C'xx...x' and X'yy...yy').

In the CHANGE and NOMATCH suboperands, you can use symbols where you can use fields (q,n), parsed fields (%nn), and constants (C'xx...x', X'yy...yy' and B'bbbbbbbb').

In the RESTART suboperand for SEQNUM, you can use a symbol where you can use a field (p,m) or a parsed field (%nn).

In the IFTHEN KEYBEGIN operand, you can use a symbol where you can use a field (p,m).

A symbol for p or p,m or p,m,f or p,m,Y2x or p,m,Y2xP results in substitution of p: for symbol: (output column).

A symbol for p,m,f results in substitution of p,m,f if (symbol),fo or symbol,TO=fo or symbol,ZDF or symbol,ZDC or symbol,PDC or symbol,PDF is specified, but results in substitution of p,m if symbol,fo is specified (when fo is not ZDF or ZDC ZDF, ZDC, PDC, or PDF) because fo cannot be distinguished from f (except for ZDF, ZDC, PDC, and PDF). For example, if SYM1 is defined as 5,4,ZD, (SYM1),PD is transformed to (5,4,ZD),PD and SYM1,TO=PD is transformed to 5,4,ZD,TO=PD, whereas SYM1,PD is transformed to 5,4,PD. Thus, you should always use (symbol),fo or symbol,TO=fo rather than symbol,fo.

A symbol for p,m,f results in substitution of p,m unless symbol,edit or symbol,to or (symbol) is specified or the symbol is part of an arithmetic expression. For example, if SYM1 is defined as 5,4,ZD, SYM1,X is transformed to 5,4,X, whereas SYM1,M12 is transformed to 5,4,ZD,M12 and SYM1,ADD,+1 is transformed to 5,4,ZD,ADD,+1.

A symbol for p,m,Y2x results in substitution of p,m,Y2x if symbol,TO=fo or symbol,todate or symbol, dateop or symbol,ZDF or symbol,ZDC or symbol,PDC or symbol,PDF is specified, but results in substitution of p,m if symbol,fo is specified (when fo is not ZDF, ZDC, PDC, or PDF) because fo cannot be distinguished from f (except for ZDF, ZDC, PDC, and PDF). For example, if SYM1 is defined as 5,4,Y2T, SYM1,TO=PD is transformed to 5,4,Y2T,TO=PD, whereas SYM1,PD is transformed to 5,4,PD. Thus, you should always use symbol,TO=fo rather than symbol,fo when dealing with symbols for p,m,Y2x fields

A symbol for p,m,Y2x results in substitution of p,m,Y2x unless symbol,f or symbol,HEX is specified. A symbol for p,m,Y2xP results in substitution of p,m,Y2xP unless symbol,f or symbol,HEX is specified.

A symbol for p,m,Y4x results in substitution of p,m,Y4x if symbol,TO=fo or symbol,todate or symbol, dateop or symbol,ZDF or symbol,ZDC or symbol,PDC or symbol,PDF is specified, but results in substitution of p,m if symbol,fo is specified (when fo is not ZDF, ZDC, PDC, or PDF) because fo cannot be distinguished from f (except for ZDF, ZDC, PDC, or PDF). For example, if SYM1 is defined as 5,8,Y4T, SYM1,TO=PD is transformed to 5,8,Y4T,TO=PD, whereas SYM1,PD is transformed to 5,4,PD. Thus, you should always use symbol,TO=fo rather than symbol,fo when dealing with symbols for p,m,Y4x fields.

A symbol for p,m,Y4x results in substitution of p,m,Y4x unless symbol,f or symbol,HEX is specified.

A symbol for 'string' always results in substitution of C'string'.

VLFILL operand: You can use symbols where you can use constants (C'x' and X'yy'). A symbol for 'string' always results in substitution of C'string'.

VLTRIM operand: You can use symbols where you can use constants (C'x' and X'yy'). A symbol for 'string' always results in substitution of C'string'.

VLTRAIL operand: You can use symbols where you can use constants (C'xx...x' and X'yy...yy'). A symbol for 'string' always results in substitution of C'string').

HEADER1 and HEADER2 operands: You can use symbols where you can use output columns (c:), fields (p,m) and non-repeated constants ('xx...x', C'xx...x', and X'yy...yy', but not n'xx...x', nC'xx...x', or nX'yy...yy'). A symbol for p or p,m or p,m,f results in substitution of p: for symbol: (output column).A symbol for p,m,f always results in substitution of p,m. A symbol for 'string' always results in substitution of C'string'.

TRAILER1 and TRAILER2 operands: Outside of the suboperands TOTAL, TOT, MIN, MAX, AVG, SUBTOTAL, SUBTOT, SUB, SUBMIN, SUBMAX and SUBAVG: You can use symbols where you can use output columns (c:), fields (p,m) and non-repeated constants ('xx...x', C'xx...x' and X'yy...yy', but not n'xx...x', nC'xx...x' or nX'yy...yy'). A symbol for p or p,m or p,m,f results in substitution of p: for symbol: (output column). A symbol for p,m,f always results in substitution of p,m. A symbol for 'string' always results in substitution of C'string'.

Inside of the suboperands TOTAL, TOT, MIN, MAX, AVG, SUBTOTAL, SUBTOT, SUB, SUBMIN, SUBMAX and SUBAVG: You can use symbols where you can use fields (p,m,f). A symbol for p,m,f results in substitution of p,m,f if symbol,TO=fo or symbol,ZDF or symbol,ZDC or symbol,PDC or symbol,PDF is specified, but results in substitution of p,m if symbol,fo is specified (when fo is not ZDF, ZDC, PDC, or PDF) because fo cannot be distinguished from f (except for ZDF, ZDC, PDC, and PDF). For example, if SYM1 is defined as 5,4,ZD, MIN=(SYM1,TO=PD) is transformed to MIN=(5,4,ZD,TO=PD) whereas MIN=(SYM1,PD) is transformed to MIN=(5,4,PD). Thus, you should always use symbol,TO=fo rather than symbol,fo.

SECTIONS operand: The "HEADER1 and HEADER2 operands" discussion shown previously also applies to the HEADER3 suboperand of SECTIONS. The "TRAILER1 and TRAILER2 operands" discussion also applies to the TRAILER3 suboperand of SECTIONS.

Outside of the HEADER3 and TRAILER3 suboperands, you can use symbols where you can use fields (p,m). A symbol for p,m,f always results in substitution of p,m.

KEYWORD=n operands: You can use a symbol where you can use a number (n) with the IFOUTLEN, RECORDS, ABSPOS, SUBPOS, ADDPOS, FIXLEN, REPEAT, STARTPOS, ENDPOS, MAXLEN, DO, ID, SEQ, START, INCR, LENGTH, STARTREC, ENDREC, SAMPLE, ACCEPT, SPLITBY, SPLIT1R and LINES operands.

Example 1
 OUTFIL FNAMES=OUT1,
       INCLUDE=(Z_Field1,GT,LIMIT,AND,Any_Format,CH,EQ,C_Field2),
       OUTREC=(Any_Format:P_Field1,M0,2X,Any_Format,BI,LENGTH=len3,2X,
               QCON,2X,
               C_Field2,HEX,2X,Z_Field1,EDIT=('I III IIT.T'),2X,
*  Lookup Table
               Lookup,CHANGE=(n6,Entry1,Value1,Entry2,Value2),
                    NOMATCH=(Lookup))
will be transformed to:
 OUTFIL FNAMES=OUT1,INCLUDE=(22,8,ZD,GT,+12500,AND,12,3,CH,EQ,4,2,CH),O*
               UTREC=(12:30,4,PD,M0,2X,12,3,BI,LENGTH=3,2X,C'Carrie''s *
               Constant',2X,4,2,HEX,2X,22,8,ZD,EDIT=('I III IIT.T'),2X,*
               52,1,CHANGE=(6,X'05',C'Read',X'20',C'Update'),NOMATCH=(5*
               2,1))
Example 2
 OUTFIL FNAMES=REPORT,
    OUTREC=(6:Branch_Office,24:Profit_or_Loss,M5,LENGTH=20,75:X),
    SECTIONS=(Division,SKIP=P,
       HEADER3=(2:Div_Title,Division,5X,'Page:',&PAGE,2/,
                   6:BO_Title,24:PL_Title,/,
                   6:BO_Hyphens,24:PL_Hyphens),
      TRAILER3=(6:BO_Equals,24:PL_Equals,/,
                   6:Total,24:TOTAL=(Profit_or_Loss,M5,LENGTH=20),/,
                   6:Lowest,24:MIN=(Profit_or_Loss,M5,LENGTH=20)))
will be transformed to:
 OUTFIL FNAMES=REPORT,OUTREC=(6:16,13,24:31,10,ZD,M5,LENGTH=20,75:X),SE*
               CTIONS=(3,10,SKIP=P,HEADER3=(2:C'Division:  ',3,10,5X,'P*
               age:',&PAGE,2/,6:C'Branch Office',24:C'       Profit/(Lo*
               ss)',/,6:C'-------------',24:C'--------------------'),TR*
               AILER3=(6:C'=============',24:C'====================',/,*
               6:C'Total',24:TOTAL=(31,10,ZD,M5,LENGTH=20),/,6:C'Lowest*
               ',24:MIN=(31,10,ZD,M5,LENGTH=20)))
Example 3
  OUTFIL IFTHEN=(WHEN=INIT,
           PARSE=(Class_value=(STARTAFT=Class_constant,
                ENDBEFR=End_constant,FIXLEN=8),
            Students_value=(STARTAFT=Students_constant,
                ENDBEFR=End_constant,FIXLEN=n5)),
            BUILD=(1:Class_value)),
          IFTHEN=(WHEN=(1,8,SS,EQ,C'Biology ,Algebra ,Geometry'),
            BUILD=(C'There are ',Students_value,UFF,M10,X,
                 Class_value,C' Students')),
          IFTHEN=(WHEN=NONE,
            BUILD=(C'*Not relevant*'))    
will be transformed to:
  OUTFIL IFTHEN=(WHEN=INIT,PARSE=(%00=(STARTAFT=C'CLASS=(',ENDBEFR=C')',*
                FIXLEN=8),%01=(STARTAFT=C'STUDENTS=(',ENDBEFR=C')',FIXLE*
                N=5)),BUILD=(1:%00)),IFTHEN=(WHEN=(1,8,SS,EQ,C'Biology ,*
                Algebra ,Geometry'),BUILD=(C'There are ',%01,UFF,M10,X,%*
                00,C' Students')),IFTHEN=(WHEN=NONE,BUILD=(C'*Not releva*
                nt*'))

Go to the previous page Go to the next page




Copyright IBM Corporation 1990, 2014