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
 

 

OUTPUT Variables in JCL

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

New User


Joined: 25 Jul 2006
Posts: 23

PostPosted: Tue Dec 19, 2006 3:49 am    Post subject: OUTPUT Variables in JCL
Reply with quote

Hi,

My program has to print a dataset to a form ID. This is the syntax generally:

SYSOUT=4,OUTPUT=*.XACT6,RECFM=FBA

But the Output variable (XACT6) has to be generated from the program based on who sends the file. The mapping will be done in a DB2 table. So

if A sends the file the Output statement should look like
"OUTPUT=*.XACT1,RECFM=FBA"

if D sends the file the Output statement should look like
"OUTPUT=*.XACT4,RECFM=FBA"

The DB2 table will have the mapping of A to XACT1 and D to XACT4.

But the problem is how to code this in the JCL as it is created from the previous step in the program. Even though I declare it as a symbolic parameter , where can I pass its value from. The assigning of the value to a symbolic parameter should be through a SET statement again which I can hard code.

Or can a set statement have a DSN name in it like
SET Variable=<DSN>

Please let me know
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: Tue Dec 19, 2006 4:08 am    Post subject:
Reply with quote

Hello,

Once the program knows the routing information, create a "new" job stream and submit it via the internal reader.

The JCL will remain the same and not need to be modified at run-time.

The "new" jcl that is created by the program will be submitted via the internal reader and discarded.
Back to top
View user's profile Send private message
gragha

New User


Joined: 25 Jul 2006
Posts: 23

PostPosted: Tue Dec 19, 2006 4:10 am    Post subject: Re: OUTPUT Variables in JCL
Reply with quote

Hi,

I thought of this once I started to research on this, but there has been a direction to do this in the same Job and not in a separate job.

Thanks.
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 Incorrect output when trying to add n... monica1 PL/I & Assembler 10 Fri Jan 13, 2017 5:02 pm
No new posts Problem in writing Output file vickey_dw COBOL Programming 5 Mon Nov 14, 2016 11:14 pm
No new posts Syncsort - Hard coded Value in output PORYES SYNCSORT 1 Thu Nov 03, 2016 9:23 am
No new posts Protection Exception while move 0 to ... Kevin Vaz CICS 10 Tue Oct 18, 2016 4:19 pm
No new posts output data in CSV Format janmejay COBOL Programming 8 Sat Oct 15, 2016 2:20 pm


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