|
|
| Author |
Message |
suganthyprabha
Active User
Joined: 28 Jul 2005 Posts: 58
|
|
|
|
Hi all,
i am having doubt in 'with' syntax of Splice option. i have seen this Jcl from Forum only. In this
i couldn't able to understand what ' with(12,1) ' means?
with(p,m) -- in this what p and m stands for? I have seen this syntax using QW.
we didn't mark CTL3 with c'12'. then how it identfies?
| Code: |
//job1 JOB (U,4019),'aaa',CLASS=0,MSGCLASS=R,MSGLEVEL=(1,1),
// NOTIFY=&SYSUID
//S1 EXEC PGM=ICETOOL
//TOOLMSG DD SYSOUT=*
//DFSMSG DD SYSOUT=*
//IN1 DD DSN=a.b.c,DISP=SHR
//IN2 DD DSN=x.y.z,DISP=SHR
//OUT12 DD SYSOUT=*
//OUT1 DD SYSOUT=*
//OUT2 DD SYSOUT=*
//T1 DD DSN=&&T1,DISP=(MOD,PASS),UNIT=SYSDA,SPACE=(TRK,(3,3))
//TOOLIN DD *
COPY FROM(IN1) TO(T1) USING(CTL1)
COPY FROM(IN2) TO(T1) USING(CTL2)
SPLICE FROM(T1) TO(OUT12) ON(1,10,CH) WITH(12,1) -
USING(CTL3) KEEPNODUPS
/*
//CTL1CNTL DD *
OUTREC FIELDS=(1,10,12:C'11')
//CTL2CNTL DD *
OUTREC FIELDS=(1,10,12:C'22')
//CTL3CNTL DD *
OUTFIL FNAMES=OUT12,INCLUDE=(12,2,CH,EQ,C'12'),OUTREC=(1,10)
OUTFIL FNAMES=OUT1,INCLUDE=(12,2,CH,EQ,C'11'),OUTREC=(1,10)
OUTFIL FNAMES=OUT2,INCLUDE=(12,2,CH,EQ,C'22'),OUTREC=(1,10)
/*
|
Thanks and regards,
prabha. |
|
| Back to top |
|
 |
References
|
|
 |
Frank Yaeger
DFSORT Moderator
Joined: 15 Feb 2005 Posts: 4579 Location: San Jose, CA
|
|
| Back to top |
|
 |
janmejay
New User
Joined: 22 Jun 2007 Posts: 18 Location: bangalore
|
|
|
|
hi i am also being strucked at same point. can anyone tell me , how it will identify CTL3 , with(12,1)
Thanks and regards,
prabha.[/quote] |
|
| Back to top |
|
 |
rajatbagga
Active User
Joined: 11 Mar 2007 Posts: 133 Location: india
|
|
|
|
Hello janmejay,
Well first use the links posted above by Frank.... you will get your answers.
Let me give you a brief idea how this works:
| Code: |
SPLICE FROM(T1) TO(OUT12) ON(1,10,CH) WITH(12,1) -
USING(CTL3) KEEPNODUPS |
The DATA present in T1 will be Spliced based on the KEY field specified in ON i.e (1,10,CH)... where 1 is the starting position and 10 is the length of KEY based on which you will perform splice operation. The values which will be spliced are specified in WITH i.e. (12,1)....where 12 is the starting position and 1 is the length of field with you want to Splice USING a control card which is specified as: USING(CTL3). So the control will go to the control card :----
| Code: |
//CTL3CNTL DD *
OUTFIL FNAMES=OUT12,INCLUDE=(12,2,CH,EQ,C'12'),OUTREC=(1,10)
OUTFIL FNAMES=OUT1,INCLUDE=(12,2,CH,EQ,C'11'),OUTREC=(1,10)
OUTFIL FNAMES=OUT2,INCLUDE=(12,2,CH,EQ,C'22'),OUTREC=(1,10)
/*
|
I hope this will help you |
|
| Back to top |
|
 |
janmejay
New User
Joined: 22 Jun 2007 Posts: 18 Location: bangalore
|
|
|
|
| how it will identify the c'12' . only c'11' and c'22' identifier is being specified in the files. |
|
| Back to top |
|
 |
janmejay
New User
Joined: 22 Jun 2007 Posts: 18 Location: bangalore
|
|
|
|
| it working fine for me. thankx |
|
| Back to top |
|
 |
|
|
|