OUTREC RDW not included in SYNCSORT



Support for NetApp SyncSort for z/OS, Visual SyncSort, SYNCINIT, SYNCLIST and SYNCTOOL

OUTREC RDW not included in SYNCSORT

Postby ramyas » Thu Sep 16, 2010 5:37 pm

Hi,

I am trying to insert 3 fields at a position of the input file depending on a condition and write it into output file. The input file is VB file and i want the output as VB file.

I have used the following sort card...

OPTION COPY                                 
OUTREC IFTHEN=(WHEN=(27,01,CH,EQ,C'1'),     
                OVERLAY=(1,4,         
                         05:5,396,         
                         396:5Z,           
                         401:5Z,           
                         406:5Z,           
                         469:396,500)) 


both the outfile and input file parameters are matching.
I am getting the error
WER235A OUTREC RDW NOT INCLUDED

I have left the first 4 bytes for RDW in output and in the input... but still its giving me the error.

Ramya
ramyas
 
Posts: 4
Joined: Thu Sep 16, 2010 4:47 pm
Has thanked: 0 time
Been thanked: 0 time

Re: OUTREC RDW not included

Postby dick scherrer » Thu Sep 16, 2010 11:22 pm

Hello,

Suggest you try BUILD.
Hope this helps,
d.sch.
User avatar
dick scherrer
Global moderator
 
Posts: 6268
Joined: Sat Jun 09, 2007 8:58 am
Has thanked: 3 times
Been thanked: 93 times

Re: OUTREC RDW not included

Postby jlipica » Fri Sep 17, 2010 11:10 am

Hi,

Even when we are trying with BUILD getting the same error( OUTREC RDW NOT INCLUDED ).

The input file format is VB and the output file is FB.

Code :
SORT FIELDS=COPY
OUTREC IFTHEN=(WHEN=(5,2,CH,EQ,C'TYPE1'),BUILD=(1:348,11,12:10,10)),
IFTHEN=(WHEN=(5,2,CH,EQ,C'TYPE2'),BUILD=(1:348,11,12:10,10))

Could anyone please provide any sample sortcard for this/A solution for this.

Regards,
Lipica
jlipica
 
Posts: 2
Joined: Fri Sep 17, 2010 10:53 am
Has thanked: 0 time
Been thanked: 0 time

Re: OUTREC RDW not included

Postby ramyas » Fri Sep 17, 2010 11:55 am

Hi,

I tried with Build, Its working fine now.
Thanks scherrer :) .

But made slight changes to get exact output.
OPTION COPY
OUTREC IFTHEN=(WHEN=(27,01,CH,EQ,C'1'),
BUILD=(1,395,
396:5Z,
401:5Z,
406:5Z,
469:396,500)) .

Lipica,

I found the following information in DFSORT manual... Pasting it here...
hope this will help u...

Converting VB to FB
You can convert a VB data set to an FB data set with OUTFIL’s VTOF and BUILD or OUTREC parameters. All of the PARSE, BUILD, or OUTREC features are available (input fields, strings, editing, and so on). For VTOF, you specify the input positions of the VB input record (with the RDW), and the output columns of the FB output record (without the RDW). DFSORT does not include the RDW in the FB output records.
Attention: You cannot specify OVERLAY or IFTHEN with VTOF.

The following JCL and DFSORT control statements convert a VB data set with LRECL=104 to an FB data set with LRECL=100:
//VBFB JOB A92,PROGRAMMER
//S1 EXEC PGM=SORT
//SYSOUT DD SYSOUT=*
//SORTIN DD DSN=A123456.VBIN,DISP=SHR
//FBOUT DD DSN=A123456.FBOUT, DISP=(NEW,CATLG,DELETE),
// UNIT=3390,SPACE=(CYL,(5,5))
//SYSIN DD *
OPTION COPY
OUTFIL FNAMES=FBOUT,VTOF,OUTREC=(5,100)
/*

Up to 100 bytes of data starting at position 5 (after the RDW) of the VB input record appears in the FB output record starting at position 1. The FB output records are all 100 bytes long. By default, if a VB input record has less than 100 data bytes, DFSORT pads the output data with blanks on the right to 100 bytes. However, you can change the padding character to anything you like with OUTFIL’s VLFILL parameter. For example, VLFILL=C’*’ pads with asterisks and VLFILL=X’00’ pads with binary zeros:

SORT FIELDS=(25,10,CH,A)
*Pad short fields on the right with blanks (default is VLFILL=C’ ’)
OUTFIL FNAMES=PADB,VTOF,
OUTREC=(41,40,C’Blank padding’,11,20)
* Pad short fields on the right with asterisks
OUTFIL FNAMES=PADA,VTOF,
OUTREC=(5,60,C’Asterisk padding’,61,40),VLFILL=C’*’.
* Pad short fields on the right with binary zeros
OUTFIL FNAMES=PADZ,VTOF,
OUTREC=(21,60,C’Binary zero padding’),VLFILL=X’00’

LRECL=73 is set for the PADB output data set, which has 73 byte FB records. Short input fields are padded with blanks on the right as needed.
LRECL=116 is set for the PADA output data set, which has 116 byte FB records. Short input fields are padded with asterisks on the right as needed.
LRECL=79 is set for the PADZ output data set, which has 79 byte FB records. Short input fields are padded with binary zeros on the right as needed.
ramyas
 
Posts: 4
Joined: Thu Sep 16, 2010 4:47 pm
Has thanked: 0 time
Been thanked: 0 time

Re: OUTREC RDW not included

Postby ramyas » Fri Sep 17, 2010 11:57 am

So... better u first convert it into FB and then apply ur conditions and Build the outrec based on the conditions.
ramyas
 
Posts: 4
Joined: Thu Sep 16, 2010 4:47 pm
Has thanked: 0 time
Been thanked: 0 time

Re: OUTREC RDW not included

Postby jlipica » Fri Sep 17, 2010 1:41 pm

Hi ramyas,

As VTOF will not work with IFTHEN. Could you please suggest any other way for the previous post.

Regards,
Lipica
jlipica
 
Posts: 2
Joined: Fri Sep 17, 2010 10:53 am
Has thanked: 0 time
Been thanked: 0 time

Re: OUTREC RDW not included

Postby shyamsaravan » Fri Sep 17, 2010 6:39 pm

Hi;

Just try this code..it will create a FB outfile as well as copied all records from VB inputfile

VB inpt LRECL=100
FB out LRECL=96

//STEP1      EXEC PGM=SORT                         
//SYSPRINT   DD SYSOUT=*                           
//SYSOUT     DD SYSOUT=*                                               
//SORTIN     DD DSN=input.VBin,           
//             DISP=SHR                           
//SORTOUT    DD DSN=output.FBOUT,           
//             DISP=(,CATLG,DELETE),           
//             UNIT=SYSDA,SPACE=(TRK,(15,15),RLSE),
//             DCB=(RECFM=FB,LRECL=96) 
//*                                               
//SYSIN    DD    *                                 
    SORT FIELDS=COPY                               
      OUTREC FIELDS=(5,96),CONVERT                 
      OUTFIL IFTHEN=(WHEN=(92,4,CH,EQ,X'00'),     
                             OVERLAY=(92:X'0C'))   


Thanks;
Saravan
shyamsaravan
 
Posts: 40
Joined: Tue May 11, 2010 7:56 pm
Has thanked: 0 time
Been thanked: 0 time

Re: OUTREC RDW not included

Postby ramyas » Fri Sep 17, 2010 6:41 pm

as per the knowledge i have...
one thing is u can convert the file into fixed and then apply OUTREC IF THEN on that file...
ramyas
 
Posts: 4
Joined: Thu Sep 16, 2010 4:47 pm
Has thanked: 0 time
Been thanked: 0 time

Re: OUTREC RDW not included

Postby MrSpock » Fri Sep 17, 2010 6:49 pm

Ramya, I know you posted some documentation out of the DFSORT manual, but I wonder if it might help the other Syncsort users such as yourself if you could post the similar information out of the Syncsort manual?
User avatar
MrSpock
Global moderator
 
Posts: 807
Joined: Wed Jun 06, 2007 9:37 pm
Location: Raleigh NC USA
Has thanked: 0 time
Been thanked: 4 times

Re: OUTREC RDW not included

Postby fornanthakumar » Thu Aug 04, 2011 3:17 pm

Hi,

Please help me out on the below option,

1. SORTIN = VB file ( total LRECL is 229 , actual length is 233 (include RDW)
2. SORTOUT = FB file ( total length is 349, file already created and i opened in share mode)

Purpose to get those 229 characters from VB file and placed in SORTOUT's file from position (100).

How do i reformat my records in SORTOUT file,
OPTION COPY
OUTFIL FNAMES=SORTOUT,VTOF,OUTREC=(100:5,229) it will give error like,

229 Fixed length will not equal to 250 LRECL of SORTOUT...

Please help me out..
Regards,
Nanthu.Y.
fornanthakumar
 
Posts: 69
Joined: Fri Oct 22, 2010 1:58 pm
Has thanked: 0 time
Been thanked: 0 time

Next

Return to Syncsort/Synctool

 


  • Related topics
    Replies
    Views
    Last post