| Author |
Message |
kvsumar
New User
Joined: 09 Mar 2008 Posts: 7 Location: bangalore
|
|
|
|
Hi,
If i give the stmts below in jcl what is the result?
| Code: |
//d1 dd dsn=one
//d2 dd dsn=two
//sysin dd dummy
//d3 dd dsn=three
|
which dataset will concatenate and why?
Thanks & Regards
kumar |
|
| Back to top |
|
 |
References
|
Posted: Thu Apr 17, 2008 1:25 pm Post subject: Re: About dataset concatenation? |
 |
|
|
 |
sri_mf
Active User
Joined: 31 Aug 2006 Posts: 120 Location: At my Desk
|
|
|
|
| kvsumar wrote: |
Hi,
If i give the stmts below in jcl what is the result?
//d1 dd dsn=one
//d2 dd dsn=two
//sysin dd dummy
//d3 dd dsn=three
which dataset will concatenate and why?
Thanks & Regards
kumar |
There is no concatenation there at all, is this an interview question? |
|
| Back to top |
|
 |
enrico-sorichetti
Global Moderator
Joined: 14 Mar 2007 Posts: 1847 Location: italy
|
|
|
|
if You look at the manuals ( link at top of the page )
the dd concatenation rules are explained in :
JCL Reference
JCL guide |
|
| Back to top |
|
 |
Anuj D.
Senior Member
Joined: 22 Apr 2006 Posts: 1124 Location: Mumbai, India
|
|
|
|
Hi,
Did you try the posted JCL..what were the results? BTW, did you concatenate something actually ?
Tough answers so far..ah..& one more I put here; Might be all these are those answers you were not looking for, but if you follow one, they would provide a better learning..for now just give a try to Enrico's suggestion & get back to us with your findings. |
|
| Back to top |
|
 |
dbzTHEdinosauer
Senior Member
Joined: 20 Oct 2006 Posts: 903 Location: germany
|
|
|
|
concatenation occurs when you have more than one dd statement for a dd reference.
in your example:
| Code: |
//d1 dd dsn=one
//d2 dd dsn=two
//sysin dd dummy
//d3 dd dsn=three
|
there is no concatenation.
in the following example, the two ds (one, and two) are concatenated for reference d1:
| Code: |
//d1 dd dsn=one,disp=shr
// dd dsn=two,disp=shr
//sysin dd dummy
//d3 dd dsn=three,disp=shr
|
I have added a disp parm soas to create a complete dd statement. |
|
| Back to top |
|
 |
Bandita Bahubalendra
New User
Joined: 08 May 2008 Posts: 3 Location: Bangalore
|
|
|
|
Hi,
This is not the correct syntax of concatenation,i do not think it wll work for cocating the dataset.u can try wit the below one.
//indd dd dsn=dd1
// dd dsn=dd2
//sysin dd dummy
//outdd dd dsn=dd3 |
|
| Back to top |
|
 |
expat
Global Moderator
Joined: 14 Mar 2007 Posts: 2194 Location: Brussels once more ...
|
|
|
|
| Why do YOU not try it yourself and let US know what happens ??? |
|
| Back to top |
|
 |
dick scherrer
Global Moderator
Joined: 23 Nov 2006 Posts: 6039 Location: 221 B Baker St
|
|
|
|
Hello,
| Quote: |
| This is not the correct syntax of concatenation |
Why do you believe this? The jcl posted by DBZ is completely correct. Yours is just another way of saying (basically) the same thing. Yours could use a disp. . .
Also, notice that earlier jcl posts are quite readable - yours is harder to read. Please practice and learn how to use the "Code" tag near the top of the Reply panel.
It is best to not post something you believe, but rather things that you have tested. |
|
| Back to top |
|
 |
Bandita Bahubalendra
New User
Joined: 08 May 2008 Posts: 3 Location: Bangalore
|
|
|
|
HI,
sorry,I have not replied to the DBZ mail.Thanks for ur information.i replied to the kvsumar mail.One thing i hv not posted it without testing it.Alredy i hv worked on that.What DBZ has given,i know it is absolutely correct. |
|
| Back to top |
|
 |
mmwife
Super Moderator
Joined: 30 May 2003 Posts: 1424
|
|
|
|
If the OP was presenting his recollection of an interview ques, it may have been this:
| Code: |
//d1 dd dsn=one
// dd dsn=two
// dd dummy
// dd dsn=three |
I've seen this on a few interviews. They want to know the effect of "dummy" on the processing of the concatenated data.
The "dummy" acts as an EOF and dsn=three is not processed. |
|
| Back to top |
|
 |
dick scherrer
Global Moderator
Joined: 23 Nov 2006 Posts: 6039 Location: 221 B Baker St
|
|
|
|
Hello BB,
| Quote: |
| sorry,I have not replied to the DBZ mail.Thanks for ur information.i replied to the kvsumar mail. |
Just a hint/suggestion. . .
When you post a reply to other than the most recent reply, it is a good idea to refer to the one you are replying to. One way to do this is to quote from the reply you want the reply to apply to. Another is to mention the poster's name.
Good luck and enjoy the forums
Jack,
Good catch, methinks
d |
|
| Back to top |
|
 |
mmwife
Super Moderator
Joined: 30 May 2003 Posts: 1424
|
|
|
|
Dick,
Methinks, too. But who know's? |
|
| Back to top |
|
 |
sril.krishy
Active User
Joined: 30 Jul 2005 Posts: 140 Location: hyderabad
|
|
|
|
what mmwife said is correct.I know it is an interview question.
Thanks
Krishy |
|
| Back to top |
|
 |
dick scherrer
Global Moderator
Joined: 23 Nov 2006 Posts: 6039 Location: 221 B Baker St
|
|
|
|
But we suspect that the way it was posted here is not the way it was asked at the interview. . .
As asked here, there was no concatenation
d |
|
| Back to top |
|
 |
|
|