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

Job Submiting from Rexx program


IBM Mainframe Forums -> CLIST & REXX
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
srinivasbathimmi

New User


Joined: 10 May 2006
Posts: 13

PostPosted: Thu Dec 09, 2010 2:11 pm
Reply with quote

Hi,

I have a requirement like display a panel and based on values entered in the panel, I need to modify few jcl statments in one jcl (exist in a PDS) and submit the job.

Code I used:

DO I = 1 TO ARR.0
IF SUBSTR(ARR.I,1,2) <> '//' & POS('TEST.TXT',ARR.I) > 0 THEN
DO
ARR.I = REPLACESTR(ARR.I,"TEST.TXT",SSHEET)
CALL REPLACESTR
QUEUE ARR.I
END
ELSE
QUEUE ARR.I
END
QUEUE "$$"
ADDRESS TSO "SUBMIT * END($$)"


Above code is working fine and the job is getting sucessfully executed.
The only concern here is before submiting the job my REXX program prints the below message and submits job only after I press the enter key

ENTER INPUT JOB STREAM:
***

Could you please let me know how can I aviod the above message and submit the job automatically
Back to top
View user's profile Send private message
expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8797
Location: Welsh Wales

PostPosted: Thu Dec 09, 2010 2:21 pm
Reply with quote

By using ISPF file tailoring services.

Why oh why do people insist on doing things the wrong way.
ISPF file tailoring with pre defined skeletons is oh so easy.
Back to top
View user's profile Send private message
dbzTHEdinosauer

Global Moderator


Joined: 20 Oct 2006
Posts: 6966
Location: porcelain throne

PostPosted: Thu Dec 09, 2010 2:23 pm
Reply with quote

I found that having a SAY statement (job autogenerated by blah blah blah)
following the SUBMIT solved the problem of having to press the enter key.

sort of a kinky work-a-round, but it works.
Back to top
View user's profile Send private message
srinivasbathimmi

New User


Joined: 10 May 2006
Posts: 13

PostPosted: Thu Dec 09, 2010 2:35 pm
Reply with quote

expat,

I am not aware of ISPF file tailoring services. If possible can you please provide me any document/link.



dbzTHEdinosauer,

I tried with SAY statement following the SUBMIT but it's not working for me.
Back to top
View user's profile Send private message
expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8797
Location: Welsh Wales

PostPosted: Thu Dec 09, 2010 2:45 pm
Reply with quote

All TSO / REXX / CLIST / ISPF documentation can be reached from the sticky topic in the CLIST & REXX forum.

And probably from the link at the top of each page marked "IBM Manuals"
Back to top
View user's profile Send private message
dbzTHEdinosauer

Global Moderator


Joined: 20 Oct 2006
Posts: 6966
Location: porcelain throne

PostPosted: Thu Dec 09, 2010 2:48 pm
Reply with quote

here is the z/OS ISPF LIBRARY
www-306.ibm.com/software/awdtools/ispf/library/
Back to top
View user's profile Send private message
srinivasbathimmi

New User


Joined: 10 May 2006
Posts: 13

PostPosted: Thu Dec 09, 2010 3:10 pm
Reply with quote

Expat,

I have gone through the link, also searched few postings and got the below code to submit the job.

"FTOPEN TEMP"
"FTINCL XXXX"
"FTCLOSE"
"VGET ZTEMPF"
ADDRESS TSO "SUBMIT '"ZTEMPF"'"

XXXX job gets submitted as is but in my requirement I have to do few jcl statement modifications and the modified jcl needs to be submitted and my original jcl should not be changed.

Can you please let me know the procedure how to achieve this using ISPF tailoring services/any other method.

Thanks in Advance.

Regards,
Srini.
Back to top
View user's profile Send private message
enrico-sorichetti

Superior Member


Joined: 14 Mar 2007
Posts: 10872
Location: italy

PostPosted: Thu Dec 09, 2010 3:17 pm
Reply with quote

Quote:
Can you please let me know the procedure how to achieve this using ISPF tailoring services

the ISPF manual will tell You all You might want to know
... the process is semi-automatic
the file tailoring processor will substitute inside the skel the variables with the same name present in Your rexx

hint
Code:
rexx code  ...
somedsn = "MY.DSN"

skel source
//DDNAME DD DISP=SHR,DSN=&SOMEDSN

ftinclude result
//DDNAME DD DISP=SHR,DSN=MY.DSN
Back to top
View user's profile Send private message
Guest







PostPosted: Thu Dec 09, 2010 3:42 pm
Reply with quote

Hi,
In order to avoid the
Quote:

ENTER INPUT JOB STREAM:
***


try using the following command:
Code:

X = OUTTRAP("OUTPUT.",'*',"CONCAT")
ADDRESS TSO "SUBMIT * END(££)"     
X = OUTTRAP('OFF')                 
Back to top
srinivasbathimmi

New User


Joined: 10 May 2006
Posts: 13

PostPosted: Thu Dec 09, 2010 5:50 pm
Reply with quote

Thank you all of you.
It's working.
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 -> CLIST & REXX

 


Similar Topics
Topic Forum Replies
No new posts Using API Gateway from CICS program CICS 0
No new posts Running REXX through JOB CLIST & REXX 13
No new posts Error to read log with rexx CLIST & REXX 11
No new posts isfline didnt work in rexx at z/OS ve... CLIST & REXX 7
No new posts run rexx code with jcl CLIST & REXX 15
Search our Forums:

Back to Top