IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

Sort using Synctool


IBM Mainframe Forums -> JCL & VSAM
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
snpavithra

New User


Joined: 22 Sep 2006
Posts: 9

PostPosted: Fri Dec 04, 2009 5:13 pm
Reply with quote

I am trying to join fields from two datasets
I am using the following JCL

Code:
//S3 EXEC PGM=SYNCTOOL
//TOOLMSG DD SYSOUT=*
//DFSMSG  DD SYSOUT=*
//IN1      DD *     
1     12    BB   08 
1     13    CC   11 
1     14    AA    4 
/*                   
//IN2     DD *       
1     12    BB    2 
1     12    AA    2 
1     12    CC    4 
1     13    CC    5 
1     13    BB    3 
1     13    AA    3 
/*                   
//OUT1     DD SYSOUT=*                                         
//T1       DD DSN=&&T1,UNIT=3390,SPACE=(CYL,(5,5)),DISP=(,PASS)
//T2       DD DSN=&&T2,UNIT=3390,SPACE=(CYL,(5,5)),DISP=(,PASS)
//CONCT    DD DSN=*.T1,VOL=REF=*.T1,DISP=(OLD,DELETE)           
//         DD DSN=*.T2,VOL=REF=*.T2,DISP=(OLD,DELETE)           
//TOOLIN   DD *                                                 
  COPY FROM(IN1) TO(T1) USING(CTL1)                             
  COPY FROM(IN2) TO(T2) USING(CTL2)                             
  SPLICE FROM(CONCT) WITHALL-                                   
    ON(13,2,CH) -                                               
    WITH(1,1) -                                                 
    TO(OUT1)                                                   
//CTL1CNTL DD *                                                 
  OUTREC FIELDS=(1:1,1,                                         
                 7:7,2,                                         
                 13:13,2,                                       
                 19:19,1)                                       
/*                                                             
//CTL2CNTL DD *                                                 
  OUTREC FIELDS=(25:18,2)                                       
//*


The job fails with the following reason :

Code:
WER428I  CALLER-PROVIDED IDENTIFIER IS "0003"                       
WER276B  SYSDIAG= 18519, 3519307, 3519307, 5382362                 
WER164B  18,708K BYTES OF VIRTUAL STORAGE AVAILABLE, MAX REQUESTED,
WER164B     0 BYTES RESERVE REQUESTED, 1,004K BYTES USED           
WER146B  20K BYTES OF EMERGENCY SPACE ALLOCATED                     
WER108I  CONCT    : RECFM=FB   ; LRECL=    19; BLKSIZE= 27987       
WER110I  OUT1     : RECFM=FB   ; LRECL=    19; BLKSIZE= 27987       
WER171A  CONCAT DS, LRECLS NE OR RECFMS DIFF                       
WER211B  SYNCSMF  CALLED BY SYNCSORT; RC=0000                       

Could anyone help me out solving this problem?

Edited: Please use BBcode when You post some code/error, that's rather readable, Thanks... Anuj
Back to top
View user's profile Send private message
enrico-sorichetti

Superior Member


Joined: 14 Mar 2007
Posts: 10872
Location: italy

PostPosted: Fri Dec 04, 2009 5:24 pm
Reply with quote

the WER.... messages indicate that You are using SYNCSORT
topic moved!
Back to top
View user's profile Send private message
Anuj Dhawan

Superior Member


Joined: 22 Apr 2006
Posts: 6250
Location: Mumbai, India

PostPosted: Fri Dec 04, 2009 5:49 pm
Reply with quote

You are concatenating T1 and T2 and they are of different LRECLs. T1 is of 19-bytes while T2 is of 26. Make a choice what you can change to make T1 and T2 compatible to get what you want. I, for one, can't suggest much on what to change, as you don't tell us the expected output.
Back to top
View user's profile Send private message
snpavithra

New User


Joined: 22 Sep 2006
Posts: 9

PostPosted: Mon Dec 07, 2009 5:00 pm
Reply with quote

Both the input IN1 and IN2 are of length 19 bytes

IN1
Code:

1 12 BB 08
1 13 CC 11
1 14 AA 4

IN2
Code:

1 12 BB 2
1 12 AA 2
1 12 CC 4
1 13 CC 5
1 13 BB 3
1 13 AA 3
1 14 AA 4

The expected output is

Code:

1 12 BB 2 08
1 12 AA 2 08
1 12 CC 4 08
1 13 CC 5 11
1 13 BB 3 11
1 13 AA 3 11
1 14 AA 4 04
Back to top
View user's profile Send private message
snpavithra

New User


Joined: 22 Sep 2006
Posts: 9

PostPosted: Mon Dec 07, 2009 5:05 pm
Reply with quote

The last column in the o/p is the (col4) from IN1 for the same (col1,col2) in IN2
Back to top
View user's profile Send private message
dbzTHEdinosauer

Global Moderator


Joined: 20 Oct 2006
Posts: 6966
Location: porcelain throne

PostPosted: Mon Dec 07, 2009 5:20 pm
Reply with quote

snpavithra wrote:
Both the input IN1 and IN2 are of length 19 bytes

that is not true, they are 80.
but who cares?

Anuj wrote:
You are concatenating T1 and T2 and they are of different LRECLs. T1 is of 19-bytes while T2 is of 26.


read your messages, as Anuj did for you;
and you have the gall to ignore his comment and write your own non-relevant garbage.

did you get this JOB from someone else?
screw it up
and now are being thickheaded??
Back to top
View user's profile Send private message
snpavithra

New User


Joined: 22 Sep 2006
Posts: 9

PostPosted: Mon Dec 07, 2009 6:47 pm
Reply with quote

Sorry if the reply was annoying. Thanks for the help
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> JCL & VSAM

 


Similar Topics
Topic Forum Replies
No new posts How to split large record length file... DFSORT/ICETOOL 10
No new posts JCL sort card - get first day and las... JCL & VSAM 9
No new posts Sort First/last record of a subset th... DFSORT/ICETOOL 7
No new posts how to calculate SUM value for VB fil... DFSORT/ICETOOL 1
No new posts how to calculate SUM for VB file usin... JCL & VSAM 1
Search our Forums:

Back to Top