kolusu Site Admin
Joined: 26 Nov 2002 Posts: 12372 Topics: 75 Location: San Jose
|
Posted: Thu Apr 28, 2005 1:21 pm Post subject: |
|
|
KM,
The following JCL will give you the desired results.
Code: |
//*****************************************************************
//* THE FOLLOWING STEP GIVES A LISTCAT INFO OF THE LEVEL *
//*****************************************************************
//STEP0100 EXEC PGM=IKJEFT01
//SYSTSPRT DD DSN=&L,DISP=(,PASS),SPACE=(CYL,(1,2),RLSE),
// RECFM=FB,LRECL=80
//SYSPRINT DD SYSOUT=*
//SYSIN DD DUMMY
//SYSTSIN DD *
LISTCAT LEVEL('AAA.I.LIA850.A1') NAME
/*
//******************************************************************
//* THE FOLLOWING STEP CREATES THE DYNAMIC SORTIN STATEMENTS *
//******************************************************************
//STEP0200 EXEC PGM=SORT
//SYSOUT DD SYSOUT=*
//SORTIN DD DSN=&L,DISP=(OLD,DELETE)
//T1 DD DSN=&T1,DISP=(,PASS),SPACE=(TRK,(1,1),RLSE)
//T2 DD DSN=&T2,DISP=(,PASS),SPACE=(TRK,(1,1),RLSE)
//SYSIN DD *
SORT FIELDS=COPY
INCLUDE COND=(1,7,CH,EQ,C'NONVSAM')
OUTFIL FNAMES=T1,ENDREC=1,
OUTREC=(C'//SORTIN',2X,C' DD DISP=SHR,DSN=',
17,44,
80:X)
OUTFIL FNAMES=T2,STARTREC=2,
OUTREC=(C'//',8X,C' DD DISP=SHR,DSN=',
17,44,
80:X)
/*
//******************************************************************
//* THE FOLLOWING STEP CREATES THE DYNAMIC JCL *
//******************************************************************
//STEP0300 EXEC PGM=ICEMAN
//SYSOUT DD SYSOUT=*
//SYSIN DD *
OPTION COPY
//SORTOUT DD SYSOUT=*
//SORTIN DD DATA,DLM=$$
//YOUR-TID JOB 'COPY',
// CLASS=A,
// MSGCLASS=Y,
// MSGLEVEL=(1,1),
// NOTIFY=&SYSUID
//*
//STEP0100 EXEC PGM=SORT
//SYSOUT DD SYSOUT=*
//SORTOUT DD DSN=YOUR OUTPUT ALL DSNCOPY,
// DISP=(NEW,CATLG,DELETE),
// UNIT=SYSDA,
// SPACE=(CYL,(X,Y),RLSE)
//SYSIN DD *
SORT FIELDS=COPY
$$
// DD DSN=&T1,DISP=(OLD,PASS)
// DD DSN=&T2,DISP=(OLD,PASS)
/* |
Run the above JCL and a take a look at the output from step0300. Once you are satisfied that you have generated the right JCL, change the following line ste0300
Code: |
//SORTOUT DD SYSOUT=*
|
To
Code: |
//SORTOUT DD SYSOUT=(*,INTRDR)
|
This will once again submit the generated JCL
Hope this helps...
Cheers
kolusu _________________ Kolusu
www.linkedin.com/in/kolusu |
|