What is the difference between SYSPRINT and SYSOUT DD names?

All sort of Mainframes Interview Questions.
Post Reply
Kannan P
Registered Member
Posts: 11
Joined: Sun Jan 03, 2016 8:08 am

What is the difference between SYSPRINT and SYSOUT DD names?

Post by Kannan P »

Hi,

When we code like this in a JCL

Code: Select all

//SYSPRINT DD SYSOUT=* 
//SYSOUT   DD SYSOUT=* 
What difference exists between SYSPRINT and SYSOUT DD names ? Why do we use SYSOUT=* in both?

I replied that they are to disply the system messages but I am not sure why we used SYSOUT=* in both? Can there be something like //SYSPRINT DD SYSPRINT=* too?
User avatar
Robert Sample
Global Moderator
Global Moderator
Posts: 1886
Joined: Fri Jun 28, 2013 1:22 am
Location: Dubuque Iowa
United States of America

Re: What is the difference between SYSPRINT and SYSOUT DD names?

Post by Robert Sample »

Some utilities use SYSPRINT and some use SYSOUT for messages; rather then remember which is used when, most programmers just code both to cover the bases. There are historical reasons for the difference, but these days those differences don't matter nearly as much.

SYSOUT=* can be referenced in the JCL Reference manual as part of the DD statement. SYSOUT= indicates to JES that you want this data spooled to print. The * indicates to use the default message class (from the JOB statement) rather than a specific message class. Most sites have different SYSOUT classes defined different ways, perhaps using special forms or special routing.
Kannan P
Registered Member
Posts: 11
Joined: Sun Jan 03, 2016 8:08 am

Re: What is the difference between SYSPRINT and SYSOUT DD names?

Post by Kannan P »

Thanks a lot Robert.
Lbdyck
Registered Member
Posts: 12
Joined: Wed Feb 10, 2016 8:42 pm

Re: What is the difference between SYSPRINT and SYSOUT DD names?

Post by Lbdyck »

The best way to answer that is that it depends on the particular program. Read the doc to see what each DD is and how it is used.
Kannan P
Registered Member
Posts: 11
Joined: Sun Jan 03, 2016 8:08 am

Re: What is the difference between SYSPRINT and SYSOUT DD names?

Post by Kannan P »

Thanks Lbdyck. But this is an interview question but I think this answer will work in interview too.
Lbdyck
Registered Member
Posts: 12
Joined: Wed Feb 10, 2016 8:42 pm

Re: What is the difference between SYSPRINT and SYSOUT DD names?

Post by Lbdyck »

Be aware that z/OS is not the same a Unix where stdout and stderr have special and agreed upon meanings. With z/OS a DD can be whatever the programmer wants it to be. Thus a SYSPRINT and a SYSOUT DD could be used for completely different purposes in different programs.

From a different perspective, SYSOUT is typically not a DD but is a DD keyword that defines the SYSOUT characteristics of the spool file that will be created by the DD.

hope this helps a bit more
Kannan P
Registered Member
Posts: 11
Joined: Sun Jan 03, 2016 8:08 am

Re: What is the difference between SYSPRINT and SYSOUT DD names?

Post by Kannan P »

Lbdyck wrote: Be aware that z/OS is not the same a Unix where stdout and stderr have special and agreed upon meanings. With z/OS a DD can be whatever the programmer wants it to be. Thus a SYSPRINT and a SYSOUT DD could be used for completely different purposes in different programs.

From a different perspective, SYSOUT is typically not a DD but is a DD keyword that defines the SYSOUT characteristics of the spool file that will be created by the DD.

hope this helps a bit more
Thanks Lbdyck.
Thus a SYSPRINT and a SYSOUT DD could be used for completely different purposes in different programs.
But for a specifc program, for example IEGENER, they will always have same meaning in all companies?
enrico-sorichetti
Global Moderator
Global Moderator
Posts: 825
Joined: Wed Sep 11, 2013 3:57 pm

Re: What is the difference between SYSPRINT and SYSOUT DD names?

Post by enrico-sorichetti »

But for a specifc program, for example IEGENER, they will always have same meaning in all companies?
as already said the meaning and the function of a DDNAME depend ONLY on the program using it
- not on the company/location/system where the program is used .
cheers
enrico
When I tell somebody to RTFM or STFW I usually have the page open in another tab/window of my browser,
so that I am sure that the information requested can be reached with a very small effort 8-)
Post Reply

Create an account or sign in to join the discussion

You need to be a member in order to post a reply

Create an account

Not a member? register to join our community
Members can start their own topics & subscribe to topics
It’s free and only takes a minute

Register

Sign in

Return to “Interview Questions.”