Problem using syncsort



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

Problem using syncsort

Postby aripallig » Tue Jul 07, 2015 7:29 am

In my jcl I have sortin & sort out as same one dataset and they are FB of length 80, when I try writing adding characters to file, characters are written correctly but the rest of the files is also been filled with ‘00’ instead of ‘0E’ As shown below
File Contents:-
Input : XXXXXXXXXXXX
Expected output is : XXXXXXXXXXXX123A
After I apply below sort card : XXXXXXXXXXXX123A……..

JCL :-
//SORTIN DD DSN=DATASET,DISP=SHR
//SORTOUT DD DSN=DATASET,DISP=SHR
//SYSIN DD*
SORT FIELDS=COPY
OUTREC FIELDS=(1:1,12,
13:C’123A’)

Please suggest what changes I need to do in my sort card to fix this.

Thanks,
Giri
aripallig
 
Posts: 1
Joined: Tue Jul 07, 2015 7:26 am
Has thanked: 0 time
Been thanked: 0 time

Re: Problem using syncsort

Postby enrico-sorichetti » Tue Jul 07, 2015 11:05 am

while You might get away using the same dataset for input and output in a SORT application
( the dataset is read into the work files and rewritten from the work files )
doing the same for a COPY application is a NONO
cheers
enrico
When I tell somebody to RTFM or STFW I usually have the page open in another tab/window of my browser,
so that I am sure that the information requested can be reached with a very small effort
enrico-sorichetti
Global moderator
 
Posts: 2994
Joined: Fri Apr 18, 2008 11:25 pm
Has thanked: 0 time
Been thanked: 164 times

Re: Problem using syncsort

Postby BillyBoyo » Tue Jul 07, 2015 12:30 pm

What do you think X'0E' is and why do you think you should see one?

As enrico has said, to use the same dataset for input and output to a COPY operation is flat-out idiotic. The same dataset name for input and output for a SORT is possible, it is termed a "Suicide SORT" by DFSORT Developers, so that may give you a clue as to whether even that is a good idea.

Change the DSNs. Don't use OUTREC for this. Never use OUTREC FIELDS (except where it already exists in code) use OUTREC BUILD. Don't use BUILD for this.

For this example:
  OPTION COPY
  INREC OVERLAY=(13:C'123A')
BillyBoyo
Global moderator
 
Posts: 3804
Joined: Tue Jan 25, 2011 12:02 am
Has thanked: 22 times
Been thanked: 265 times


Return to Syncsort/Synctool

 


  • Related topics
    Replies
    Views
    Last post