Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

Concatenate only the 1,3,6 datasets from 6 datasets

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> JCL & VSAM
View previous topic :: :: View next topic  
Author Message
Raju.main

New User


Joined: 26 Apr 2007
Posts: 4
Location: noida

PostPosted: Wed May 02, 2007 6:21 pm    Post subject: Concatenate only the 1,3,6 datasets from 6 datasets
Reply with quote

// step1 dd dsn=name file name 1
// dd dsn = name2 filename 2
// dd dsn=name3 file name3
// dd dsn=name4 file name4
// dd dsn=name5 file name5
// dd dsn=name6 file name6


i have above jcl to concatenate the 6 datasets.....
But my requirement is have to concatenate only the 1,3,6 datasets only.....
for this one what can i do.....here condition dont make comment the jcl line....
Back to top
View user's profile Send private message

expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8593
Location: Back in jolly old England

PostPosted: Wed May 02, 2007 6:26 pm    Post subject:
Reply with quote

Is this instream JCL or in a PROC ?
Back to top
View user's profile Send private message
agkshirsagar

Active Member


Joined: 27 Feb 2007
Posts: 685
Location: Earth

PostPosted: Wed May 02, 2007 6:27 pm    Post subject:
Reply with quote

what's the problem here? Go ahead..
Back to top
View user's profile Send private message
Raju.main

New User


Joined: 26 Apr 2007
Posts: 4
Location: noida

PostPosted: Wed May 02, 2007 6:31 pm    Post subject: hi expat
Reply with quote

what is difference if it is instream and if it is PROC.....
Give clear idea on both cases
Back to top
View user's profile Send private message
Raju.main

New User


Joined: 26 Apr 2007
Posts: 4
Location: noida

PostPosted: Wed May 02, 2007 6:33 pm    Post subject: hi agkshirsagar
Reply with quote

the problem here i dont want to concatenate datasets 2,4,5.......i want concatenate only 1,3,6.......
Back to top
View user's profile Send private message
expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8593
Location: Back in jolly old England

PostPosted: Wed May 02, 2007 7:32 pm    Post subject:
Reply with quote

Yes, we know what you want to do, but the actions and code required for instream JCL will be different from the code required if in a proc.
Back to top
View user's profile Send private message
Raju.main

New User


Joined: 26 Apr 2007
Posts: 4
Location: noida

PostPosted: Fri May 04, 2007 8:30 am    Post subject: Re: Concatenate only the 1,3,6 datasets from 6 datasets
Reply with quote

HI Expat,
Can you say that if it is instream Proc
Back to top
View user's profile Send private message
expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8593
Location: Back in jolly old England

PostPosted: Fri May 04, 2007 12:03 pm    Post subject:
Reply with quote

What I mean is .................

Is the JCL that you execute in a PROC

//SOMETHNG EXEC PROCNAME

or is it instream as that you can see and edit lots and lots of JCL statements.
Back to top
View user's profile Send private message
rameshfoa

New User


Joined: 05 Apr 2007
Posts: 27
Location: chennai

PostPosted: Mon May 07, 2007 1:37 pm    Post subject:
Reply with quote

If it is in a external PROC then give the dummy override for 2,4,6 datasets...

ex:

0010 //s1 exec proc1
0020 //step1.dd2 dd dummy
0030 //step1.dd4 dd dummy

If it instream proc...then just comment the datasets..
Back to top
View user's profile Send private message
expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8593
Location: Back in jolly old England

PostPosted: Mon May 07, 2007 2:02 pm    Post subject:
Reply with quote

rameshfoa
Code:

//s1 exec proc1
//step1.dd2 dd dummy
//step1.dd4 dd dummy

I think not. As soon as the first DD DUMMY is encountered the remainder of the files in the DD statement will ignored.

But as the OP has not been back and answered if this is a PROC or instream JCL, how can we give the correct assistence ?
Back to top
View user's profile Send private message
expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8593
Location: Back in jolly old England

PostPosted: Mon May 07, 2007 2:05 pm    Post subject:
Reply with quote

Also, your JCL does not resemble the current problem as originally posted, because you are changing the allocation to seperate DD statements, whereas the OP has all of the datasets allocated to only one DD statement.
Back to top
View user's profile Send private message
rameshfoa

New User


Joined: 05 Apr 2007
Posts: 27
Location: chennai

PostPosted: Mon May 07, 2007 2:39 pm    Post subject:
Reply with quote

then it dhud be as follows...

0010 //s1 exec proc1
0020 //step1.dd1 dd dataset1
0030 // dd dummy
0030 // dd dataset3
0040 // dd dummy
Back to top
View user's profile Send private message
expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8593
Location: Back in jolly old England

PostPosted: Mon May 07, 2007 2:53 pm    Post subject:
Reply with quote

Quote:
I think not. As soon as the first DD DUMMY is encountered the remainder of the files in the DD statement will ignored.

What I am telling yo is that when you use your code,
Code:

0010 //s1 exec proc1
0020 //step1.dd1 dd dataset1
0030 // dd dummy
0030 // dd dataset3
0040 // dd dummy

the desired output will not be achieved. Line 0030 contains DD DUMMY, so ALL other concatenations that follow within that DD staement will be ignored. Dataset3 will not be included in the concatenation.

Try it, and let us know what happens.
Back to top
View user's profile Send private message
dick scherrer

Site Director


Joined: 23 Nov 2006
Posts: 19270
Location: Inside the Matrix

PostPosted: Mon May 07, 2007 9:58 pm    Post subject:
Reply with quote

Hello,

I'd suggest overriding all 6 DD statements - the first 3 with the 3 files you want to use as input and the last 3 as dummy. When the first dummy is encountered, the read should end, but overriding the last 3 with dummy will make it easier to understand if anyone looks at the run jcl after the job has been executed.
Back to top
View user's profile Send private message
sh_moni
Currently Banned

New User


Joined: 30 Apr 2007
Posts: 7
Location: pune

PostPosted: Tue May 08, 2007 7:54 pm    Post subject: Concatenate only the 1,3,6 datasets from 6 datasets
Reply with quote

hi expat,

Could you please give the answer for both the cases(Instream and Catalog Procs).

//s1 exec proc1
//step1.dd1 dd dataset1
//step1.dd3 dd dataset3
//step1.dd6 dd dataset6
// dd dummy

will this work in above case.
Back to top
View user's profile Send private message
expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8593
Location: Back in jolly old England

PostPosted: Tue May 08, 2007 8:06 pm    Post subject:
Reply with quote

Quote:
will this work in above case.

The answer is NO.

The reason is the same as I said for rameshfoa.

Here's the code from the OP

// step1 dd dsn=name file name 1
// dd dsn = name2 filename 2
// dd dsn=name3 file name3
// dd dsn=name4 file name4
// dd dsn=name5 file name5
// dd dsn=name6 file name6

To me it looks like it is instream JCL, and not in a PROC.

I would code

// step1 dd dsn=name1 file name 1
// dd dsn = name3 filename 3
// dd dsn=name6 file name6
// dd dummy
// dd dummy
// dd dummy

For a PROC it is virtually the same apart from coding stepname. infront of the DD name
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> JCL & VSAM All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts DUMP DATASETS VS TRACE DATASETS! lind sh CICS 4 Tue Dec 06, 2016 11:31 pm
No new posts Single COPY CICS TS datasets and when... Kyle Carroll CICS 2 Tue Oct 11, 2016 9:47 pm
No new posts Finding unreferenced datasets without... Alan Playford JCL & VSAM 5 Tue Jul 12, 2016 9:07 pm
No new posts BDW in VB datasets harisukumaran JCL & VSAM 5 Sat May 28, 2016 9:46 am
No new posts How to sync memebers in some datasets... Lord.of.Wind Compuware & Other Tools 2 Thu Apr 21, 2016 12:48 pm


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us