af dc at IBM Mainframe Discussion List <
IBM-...@bama.ua.edu> wrote on
02/09/2012 03:45:23 AM:
> From: af dc <
acb...@GMAIL.COM>
> To:
IBM-...@bama.ua.edu
> Date: 02/09/2012 03:47 AM
> Subject: ICETOOL extract fields from input dsn and copy to an output dsn
> Sent by: IBM Mainframe Discussion List <
IBM-...@bama.ua.edu>
>
> Hello,
> I'm hanging around with this task and I'm not getting what I want, can
you pls
> give me an help ??
>
> >> input dsn:
> Organization . . . : PS
> Record format . . . : VB
> ...
> I'm using ICETOOL with:
> //TOOLIN DD *
> *
> COPY FROM(INDD) TO(OUT1) USING(COP1)
> *
> //COP1CNTL DD *
> SORT FIELDS=COPY
> OUTREC FIELDS=(9,40)
> and I'm getting:
>
> ICE251A 0 MISSING RDW OR DATA FOR *OUTREC : REASON CODE 03, IFTHEN 0
>
>
> What am I missing ??
As indicated by the ICE251A message, you're missing the RDW in the
OUTREC statement.
You have a VB input file, but you're treating it like an
FB input file.
If you want a VB output file, you can use a
DFSORT/ICETOOL job like the following:
//S1 EXEC PGM=ICETOOL
//TOOLMSG DD SYSOUT=*
//DFSMSG DD SYSOUT=*
//INDD DD DSN=.... input file (VB)
//OUT1 DD DSN=... output file (VB)
//TOOLIN DD *
COPY FROM(INDD) TO(OUT1) USING(COP1)
*
//COP1CNTL DD *
SORT FIELDS=COPY
OUTREC BUILD=(1,4,9,40)
/*
Note that you must specify the RDW (1,4) in OUTREC.
If you want an FB output file, you can use
a DFSORT/ICETOOL job like the following:
//S2 EXEC PGM=ICETOOL
//TOOLMSG DD SYSOUT=*
//DFSMSG DD SYSOUT=*
//INDD DD DSN=.... input file (VB)
//OUT1 DD DSN=... output file (FB)
//TOOLIN DD *
COPY FROM(INDD) USING(COP1)
*
//COP1CNTL DD *
SORT FIELDS=COPY
OUTFIL FNAMES=OUT1,BUILD=(9,40),VTOF
/*
Note the use of VTOF.
Frank Yaeger - DFSORT Development Team (IBM) -
yae...@us.ibm.com
Specialties: JOINKEYS, FINDREP, WHEN=GROUP, ICETOOL, Symbols, Migration
=> DFSORT/MVS is on the Web at
http://www.ibm.com/storage/dfsort