Syncsort - Copy and Reformat



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

Re: Syncsort - Copy and Reformat

Postby ranga_subham » Wed Sep 12, 2012 8:13 am

I tried that but it ends with abend stating that "OUTREC Statement Syntax error" that means overlay is not possible.
ranga_subham
 
Posts: 279
Joined: Fri Jul 18, 2008 7:46 pm
Has thanked: 0 time
Been thanked: 1 time

Re: Re: Syncsort - Copy and Reformat

 

Re: Syncsort - Copy and Reformat

Postby ranga_subham » Wed Sep 12, 2012 8:19 am

Here it is with error:

 SYSIN :                                                         
   SORT FIELDS=COPY                                               
   OUTREC IFTHEN=(WHEN=GROUP,BEGIN=(58,3,CH,EQ,C'#T#'),           
                  PUSH=(75:1,72)),                               
          IFTHEN=(WHEN=(58,3,CH,EQ,C'#T#'),                       
                  BUILD=(13:84,15,75,4,37:10,62)),               
          IFTHEN=(WHEN=NONE,BUILD=(1:92,2,3:37,2,5:6,6,11:37,2,   
                                   13:84,15,28:1,72)),           
          IFTHEN=(WHEN=(21,1,CH,EQ,C'C'),OVERLAY=(1:C'12'))       
                                        *                         
 WER268A  OUTREC STATEMENT  : SYNTAX ERROR                       
 WER449I  SYNCSORT GLOBAL DSM SUBSYSTEM ACTIVE                   


Thanks.
ranga_subham
 
Posts: 279
Joined: Fri Jul 18, 2008 7:46 pm
Has thanked: 0 time
Been thanked: 1 time

Re: Syncsort - Copy and Reformat

Postby dick scherrer » Wed Sep 12, 2012 8:53 am

Hello,

Which release of Syncsort is being used?
Hope this helps,
d.sch.
User avatar
dick scherrer
Global moderator
 
Posts: 6304
Joined: Sat Jun 09, 2007 8:58 am
Has thanked: 3 times
Been thanked: 91 times

Re: Syncsort - Copy and Reformat

Postby ranga_subham » Wed Sep 12, 2012 10:10 am

SYNCSORT FOR Z/OS 1.3.2.2R


Thanks.
ranga_subham
 
Posts: 279
Joined: Fri Jul 18, 2008 7:46 pm
Has thanked: 0 time
Been thanked: 1 time

Re: Syncsort - Copy and Reformat

Postby BillyBoyo » Wed Sep 12, 2012 12:10 pm

ranga_subham,

You have to check in your manual what order you are allowed for the different IFTHEN's.

You'll certainly find that WHEN=NONE has to be last.

You are putting data into column one in the WHEN=NONE. I don't understand that bit.
BillyBoyo
Global moderator
 
Posts: 3804
Joined: Tue Jan 25, 2011 12:02 am
Has thanked: 22 times
Been thanked: 264 times

Re: Syncsort - Copy and Reformat

Postby bodatrinadh » Wed Sep 12, 2012 3:40 pm

Try this code...

//SYSPRINT DD SYSOUT=*                                               
//SYSOUT DD SYSOUT=*                                     
//SORTIN  DD *                           
----+----1----+----2----+----3----+----4----+----5----+----6----+----7----+----8
SRT3     STATUSFL1303404GH6                              #T#
31055ABC0121X6AL5S3 D0      3012052512X226111290N   6AB6922521420
33111XYZ1231Y6AH5S3 D1      3012070312Y2282     N   6AB6922521420
MUT4     STATUSFL1400048MK3                              #T#
74620DEF2134G1J86CC E1      3012090572Z313372650N   1JC4822521243
74620ZEB3218G1J86CC E2      3012090572O313372650N   1JD4822521243
//SORTOUT DD SYSOUT=*                                                 
//SYSIN    DD *                                                       
  INREC IFTHEN=(WHEN=(58,3,CH,EQ,C'#T#'),
                BUILD=(13:10,15,28:1,4,37:10,18,58:58,3)),
        IFTHEN=(WHEN=(21,1,CH,EQ,C'D'),BUILD=(01:C'13',03:37,2,05:6,6,
                11:37,2,28:1,53)),
        IFTHEN=(WHEN=(21,1,CH,EQ,C'E'),BUILD=(01:C'14',03:37,2,05:6,6,
                11:37,2,28:1,53))
  SORT FIELDS=COPY
 OUTREC IFTHEN=(WHEN=GROUP,BEGIN=(58,3,CH,EQ,C'#T#'),PUSH=(13:13,15)),
        IFTHEN=(WHEN=(58,3,CH,EQ,C'#T#'),OVERLAY=(58:3X))


Your Output :-

----+----1----+----2----+----3----+----4----+----5----+----6----+----7----+----8
            STATUSFL1303404SRT3     STATUSFL1303404GH6
1312ABC01212STATUSFL130340431055ABC0121X6AL5S3 D0      3012052512X226111290N   6
1312XYZ12312STATUSFL130340433111XYZ1231Y6AH5S3 D1      3012070312Y2282     N   6
            STATUSFL1400048MUT4     STATUSFL1400048MK3
1472DEF21372STATUSFL140004874620DEF2134G1J86CC E1      3012090572Z313372650N   1
1472ZEB32172STATUSFL140004874620ZEB3218G1J86CC E2      3012090572O313372650N   1
Thanks
-3nadh
User avatar
bodatrinadh
 
Posts: 67
Joined: Thu Jan 12, 2012 9:05 pm
Has thanked: 0 time
Been thanked: 4 times

Re: Syncsort - Copy and Reformat

Postby ranga_subham » Wed Sep 12, 2012 7:19 pm

Hi,

Thanks.......Yes.......got the results.......... :D
ranga_subham
 
Posts: 279
Joined: Fri Jul 18, 2008 7:46 pm
Has thanked: 0 time
Been thanked: 1 time

Previous

Return to Syncsort/Synctool

 


  • Related topics
    Replies
    Views
    Last post