I'm using SYNCTOOL to run a SELECT from a DB2 table and to register duplicated records in a file, with no success. What am I missing if SORTDBIN is included in JCL ?
SYNCTOOL calls SYNCSORT in our installation.
Here is the jcl:
//PASO20 EXEC PGM=SYNCTOOL,REGION=0M
//$ORTPARM DD *
DB2=DB2M
//SORTDBIN DD DISP=SHR,DSN=hlq.CNTL(SORTDBIN) <---- Here is the select
//SORTDBOU DD DSN=hlq.SYSREC00,DISP=(,CATLG,KEEP),
// SPACE=(CYL,(5,5),RLSE),UNIT=3390,
// DCB=(LRECL=571,RECFM=FB,DSORG=PS,BLKSIZE=27979)
//DD1 DD DSN=hlq.DD1,DISP=(,CATLG,KEEP),
// SPACE=(CYL,(5,5),RLSE),UNIT=3390,DCB=*.SORTDBOU
//DD2 DD DSN=hlq.DUP,DISP=(,CATLG,KEEP),
.... ---> other system outputs DD's like sysout
//TOOLMSG DD SYSOUT=*
//DFSMSG DD SYSOUT=*
//TOOLIN DD *
COPY FROM(SORTDBOU) TO(DD1) USING(CTL1)
SELECT FROM(SORTDBOU) TO(DD2) ALLDUPS ON(20,19,CH)
//CTL1CNTL DD *
SORT FIELDS=(571,1,CH,A),EQUALS
OUTREC BUILD=(1,571)
//$ORTPARM DD *
DB2=DB2M
//SORTDBIN DD DISP=SHR,DSN=hlq.CNTL(SORTDBIN) <---- Here is the select
//SORTDBOU DD DSN=hlq.SYSREC00,DISP=(,CATLG,KEEP),
// SPACE=(CYL,(5,5),RLSE),UNIT=3390,
// DCB=(LRECL=571,RECFM=FB,DSORG=PS,BLKSIZE=27979)
//DD1 DD DSN=hlq.DD1,DISP=(,CATLG,KEEP),
// SPACE=(CYL,(5,5),RLSE),UNIT=3390,DCB=*.SORTDBOU
//DD2 DD DSN=hlq.DUP,DISP=(,CATLG,KEEP),
.... ---> other system outputs DD's like sysout
//TOOLMSG DD SYSOUT=*
//DFSMSG DD SYSOUT=*
//TOOLIN DD *
COPY FROM(SORTDBOU) TO(DD1) USING(CTL1)
SELECT FROM(SORTDBOU) TO(DD2) ALLDUPS ON(20,19,CH)
//CTL1CNTL DD *
SORT FIELDS=(571,1,CH,A),EQUALS
OUTREC BUILD=(1,571)
SYNCTOOL OUTUPUT MESSAGE:
SYNCSORT LICENSED FOR CPU SERIAL NUMBER xxxxx, MODEL 2964 507 LICEN
$ORTPARM : DB2=DB2M
SORT FIELDS=(571,1,CH,A),EQUALS
OUTREC BUILD=(1,571)
PARMLIST :
OPTION RESINV=0,ARESINV=0,MSGDDN=DFSMSG,SORTIN=SORTDBOU,SORTOUT=DD1,SORTDD=CTL1
SORT FIELDS=COPY
WER813I INSTALLATION OPTIONS IN MFXPRMD1 WILL BE USED
WER428I CALLER-PROVIDED IDENTIFIER IS "0001"
WER161B ALTERNATE PARM USED
WER276B SYSDIAG= 1268629, 1697870, 1697870, 1389460
WER426G AVAILABLE STORAGE RESOURCES: 666,860K EXCESS CENTRAL, 666,860K EXPANDED
WER164B 13,840K BYTES OF VIRTUAL STORAGE AVAILABLE, MAX REQUESTED,
WER164B 0 BYTES RESERVE REQUESTED, 2,024K BYTES USED
WER146B 20K BYTES OF EMERGENCY SPACE ALLOCATED
WER468A DB2 QUERY SUPPORT ERROR: SORTDBIN CANNOT BE FOUND
WER211B SYNCSMF CALLED BY SYNCSORT; RC=0000
WER449I SYNCSORT GLOBAL DSM SUBSYSTEM ACTIVE
$ORTPARM : DB2=DB2M
SORT FIELDS=(571,1,CH,A),EQUALS
OUTREC BUILD=(1,571)
PARMLIST :
OPTION RESINV=0,ARESINV=0,MSGDDN=DFSMSG,SORTIN=SORTDBOU,SORTOUT=DD1,SORTDD=CTL1
SORT FIELDS=COPY
WER813I INSTALLATION OPTIONS IN MFXPRMD1 WILL BE USED
WER428I CALLER-PROVIDED IDENTIFIER IS "0001"
WER161B ALTERNATE PARM USED
WER276B SYSDIAG= 1268629, 1697870, 1697870, 1389460
WER426G AVAILABLE STORAGE RESOURCES: 666,860K EXCESS CENTRAL, 666,860K EXPANDED
WER164B 13,840K BYTES OF VIRTUAL STORAGE AVAILABLE, MAX REQUESTED,
WER164B 0 BYTES RESERVE REQUESTED, 2,024K BYTES USED
WER146B 20K BYTES OF EMERGENCY SPACE ALLOCATED
WER468A DB2 QUERY SUPPORT ERROR: SORTDBIN CANNOT BE FOUND
WER211B SYNCSMF CALLED BY SYNCSORT; RC=0000
WER449I SYNCSORT GLOBAL DSM SUBSYSTEM ACTIVE
Thanks in advance,
Amelia Quiroga
Edited to include code tags. Also removed 'bolding' (it makes no difference on my machine)