IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

OUTPUT Variables in JCL


IBM Mainframe Forums -> JCL & VSAM
Post new topic   Reply to topic
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
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

Moderator Emeritus


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

PostPosted: Tue Dec 19, 2006 4:08 am
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
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 View Bookmarks
All times are GMT + 6 Hours
Forum Index -> JCL & VSAM

 


Similar Topics
Topic Forum Replies
No new posts TRIM everything from input, output co... DFSORT/ICETOOL 1
No new posts Sortjoin and Search for a String and ... DFSORT/ICETOOL 1
No new posts Joinkeys - 5 output files DFSORT/ICETOOL 7
No new posts Build a record in output file and rep... DFSORT/ICETOOL 11
No new posts XDC SDSF output to temp dataset CLIST & REXX 4
Search our Forums:

Back to Top