Changing a DDNAME in a JCL.



JES, JES2, JCL utilities, IDCAMS, Compile & Run JCLs, PROCs etc...

Changing a DDNAME in a JCL.

Postby vinodj » Tue Mar 20, 2012 7:14 pm

Hello,

I have following statement in my JCL.

//SYSOUT DD SYSOUT=*

I want to change the DDNAME SYSOUT to DATAS so that when it will be diaplayed in SPOOL i should be able to see all the messages under DATAS and not SYSOUT . I did following to achieve this:
//DATAS DD SYSOUT=*
For this I am getting error "SYSOUT statement missing".

Please tell me how could this be achieved.

Regards,
Vinod.
vinodj
 
Posts: 29
Joined: Wed Nov 23, 2011 6:16 pm
Has thanked: 0 time
Been thanked: 0 time

Re: Changing a DDNAME in a JCL.

Postby Akatsukami » Tue Mar 20, 2012 7:28 pm

You can't.
"You have sat too long for any good you have been doing lately ... Depart, I say; and let us have done with you. In the name of God, go!" -- what I say to a junior programmer at least once a day
User avatar
Akatsukami
Global moderator
 
Posts: 1058
Joined: Sat Oct 16, 2010 2:31 am
Location: Bloomington, IL
Has thanked: 6 times
Been thanked: 51 times

Re: Changing a DDNAME in a JCL.

Postby steve-myers » Tue Mar 20, 2012 7:46 pm

Akatsukami is correct. The purpose of the DD name in

//SYSOUT DD SYSOUT=*

is to provide a link to a dataset; in this case a dataset that the system will print, but it can be a "regular" dataset. If you want to change the DD name you must change the application, or tell the application to use a different DD name, if that is possible.
steve-myers
Global moderator
 
Posts: 2105
Joined: Thu Jun 03, 2010 6:21 pm
Has thanked: 4 times
Been thanked: 243 times

Re: Changing a DDNAME in a JCL.

Postby BillyBoyo » Tue Mar 20, 2012 7:54 pm

What program is writing to SYSOUT? How is it writing to SYSOUT? If the answers are COBOL and DISPLAY then there is a compile option you can use to change the default that DISPLAY uses.

If those are not the answers, then let us know what they are :-)
BillyBoyo
Global moderator
 
Posts: 3804
Joined: Tue Jan 25, 2011 12:02 am
Has thanked: 22 times
Been thanked: 265 times

Re: Changing a DDNAME in a JCL.

Postby vinodj » Wed Mar 21, 2012 12:10 pm

Hello Billy,

It is COBOL program that is writing to SYSOUT. I will search for this compiler option that can change the default DISPLAY uses.

Thanks.
vinodj
 
Posts: 29
Joined: Wed Nov 23, 2011 6:16 pm
Has thanked: 0 time
Been thanked: 0 time

Re: Changing a DDNAME in a JCL.

Postby Aditya Jain » Wed Mar 21, 2012 8:01 pm

If you really want to display it as DATAS you can do so by declaring a DATAS file name in the cobol code and perform write(s) to the DATAS file in the cobol code
include the following line in the JCL
//DATAS DD SYSOUT=*

I have not tried this.. I am still a novice at mainframes.. but according to my instincts, this should work..
Aditya Jain
 
Posts: 11
Joined: Fri Dec 30, 2011 8:55 pm
Has thanked: 0 time
Been thanked: 0 time

Re: Changing a DDNAME in a JCL.

Postby Robert Sample » Wed Mar 21, 2012 8:18 pm

Look in the COBOL Application Programming Guide and check out the OUTDD compiler option. This MAY do what you want, depending upon the COBOL code.
Robert Sample
Global moderator
 
Posts: 3719
Joined: Sat Dec 19, 2009 8:32 pm
Location: Dubuque, Iowa, USA
Has thanked: 1 time
Been thanked: 279 times

Re: Changing a DDNAME in a JCL.

Postby vinodj » Thu Mar 22, 2012 7:06 pm

Hello,

I found following on internet for OUTDD and tried to apply this in my JCL but got an error 'Overridden step not found in procedure'

//JS10 EXEC PROC=COB2UC, IBM-supplied proc
// PARM.COB=(OFFSET,OUTDD(DSPOUT)) Optional Parms
//COB.SYSIN DD * Source Program Input source program...

/* The example above shows sample JCL required to execute the compiler via the COB2UC JCL procedure supplied by IBM. In this case, the following options are specified: OFFSET: to request a condensed PROCEDURE DIVISION listing OUTDD: to request that execution time DISPLAY output use a ddname of DSPOUT LANGUAGE: This is a COBOL compiler option. Format: LANGUAGE(xxxxxx) Abbreviations: LANG(xx) IBM-default: LANGUAGE(ENGLISH) LANGUAGE specifies the language that will be used for compiler messages (i.e., for diagnostic messages, message summary headers, the compilation summary, and various headers and notations resulting from the use of compiler options like MAP, XREF, etc.). The language sub-parameters that may be specified are shown Sub-parameter Abbreviation Description
vinodj
 
Posts: 29
Joined: Wed Nov 23, 2011 6:16 pm
Has thanked: 0 time
Been thanked: 0 time

Re: Changing a DDNAME in a JCL.

Postby BillyBoyo » Thu Mar 22, 2012 7:14 pm

You should talk to your site support about specifying an option which is different from your site's standard.

If you are able, you can just put a CBL OUTDD(your required ddname) card at the beginning of your source, but your site probably has a preferred way to do it. Explain your requirement to them.
BillyBoyo
Global moderator
 
Posts: 3804
Joined: Tue Jan 25, 2011 12:02 am
Has thanked: 22 times
Been thanked: 265 times

Re: Changing a DDNAME in a JCL.

Postby Akatsukami » Thu Mar 22, 2012 7:41 pm

vinodj wrote:Hello,

I found following on internet for OUTDD and tried to apply this in my JCL but

since you didn't understand what you were doing or why, you failed miserably. You don't actually know JCL, do you?
"You have sat too long for any good you have been doing lately ... Depart, I say; and let us have done with you. In the name of God, go!" -- what I say to a junior programmer at least once a day
User avatar
Akatsukami
Global moderator
 
Posts: 1058
Joined: Sat Oct 16, 2010 2:31 am
Location: Bloomington, IL
Has thanked: 6 times
Been thanked: 51 times

Next

Return to JCL

 


  • Related topics
    Replies
    Views
    Last post