View previous topic :: View next topic |
Author |
Message |
vijay_pampana Beginner
Joined: 11 Nov 2008 Posts: 9 Topics: 2
|
Posted: Wed Nov 12, 2008 5:02 am Post subject: View and modify JCL and submit the job through rexx |
|
|
Hi,
I am written a REXX tool which will open a PS file in view mode containing a JCL. The user can make all the changes in the JCL and submits the Job.
Code: | ADDRESS ISPEXEC "VIEW DATASET('"FILE1"')" |
Where FIle1 contains the dataset that the user want to view.
When I make any changes to the JCL which is opened in the view mode, I could able to come out of the PS file as it is giving a error message. After submitting the code when I press CANCEL and ENTER it is giving the following error message.
INVALID COMMAND
When I used the EDIT mode it is working for me but I want to make sure there are no changes to the JCL's
Thanks
--Vijay |
|
Back to top |
|
 |
dbzTHEdinosauer Supermod
Joined: 20 Oct 2006 Posts: 1411 Topics: 26 Location: germany
|
Posted: Wed Nov 12, 2008 5:14 am Post subject: |
|
|
what commands in your REXX tool follow the 'VIEW' command in your post? _________________ Dick Brenholtz
American living in Varel, Germany |
|
Back to top |
|
 |
vijay_pampana Beginner
Joined: 11 Nov 2008 Posts: 9 Topics: 2
|
Posted: Wed Nov 12, 2008 5:32 am Post subject: |
|
|
Please find the code below.
If the option entered by the user V it comes this IF condition
Code: | ELSE IF RESETSWITCH = 'V' THEN DO
FILE10 = FILE1'('JOBNAME')'
ADDRESS ISPEXEC "VIEW DATASET('"FILE10"')"
SAY "PLEASE PROVIDE THE JOB DETAILS OF THE SUBMITTED JOB"
PULL DETAILS
PARSE VAR DETAILS JOBNAM1 "(" JOBID ")" . |
Thanks
--Vijay |
|
Back to top |
|
 |
vijay_pampana Beginner
Joined: 11 Nov 2008 Posts: 9 Topics: 2
|
Posted: Wed Nov 12, 2008 5:34 am Post subject: |
|
|
As the job is submitted by the user you need to provide the jobname and jobid details to the rexx program so that it will place them in the PS file for debugging later. |
|
Back to top |
|
 |
Dibakar Advanced

Joined: 02 Dec 2002 Posts: 700 Topics: 63 Location: USA
|
Posted: Wed Nov 12, 2008 4:43 pm Post subject: |
|
|
What is the complete error message. Press PF1 and find the complete error. |
|
Back to top |
|
 |
Santlou Beginner
Joined: 18 Apr 2007 Posts: 21 Topics: 4 Location: sw florida
|
Posted: Wed Nov 12, 2008 6:18 pm Post subject: |
|
|
As an alternative, why don't you use a skeleton file and use ISPF File Tailoring to edit the JCL. This way, you can keep the JCL in the skeleton library and substitute the required Jobcard info dynamically. |
|
Back to top |
|
 |
vijay_pampana Beginner
Joined: 11 Nov 2008 Posts: 9 Topics: 2
|
Posted: Wed Nov 12, 2008 10:54 pm Post subject: |
|
|
The complete error message which displayed when I entered the PF1 key is:
Only ISPF system commands may be entered on this panel.
I know the alternative of using skels for this, but I want to know why it is not working in view. |
|
Back to top |
|
 |
Nic Clouston Advanced
Joined: 01 Feb 2007 Posts: 1075 Topics: 7 Location: At Home
|
Posted: Thu Nov 13, 2008 3:25 pm Post subject: |
|
|
When you say 'press CANCEL and ENTER' do you mean tyoe CANCEL and press ENTER? If not then it is probably objecting to the CANCEL key - unless that is an FKey that has CANCEL assigned to it. But you would not need the ENTER key if it was an Fkey. _________________ Utility and Program control cards are NOT, repeat NOT, JCL. |
|
Back to top |
|
 |
vijay_pampana Beginner
Joined: 11 Nov 2008 Posts: 9 Topics: 2
|
Posted: Thu Nov 13, 2008 8:23 pm Post subject: |
|
|
I am facing the same issue when I am using PF3 and Enter also. |
|
Back to top |
|
 |
vijay_pampana Beginner
Joined: 11 Nov 2008 Posts: 9 Topics: 2
|
Posted: Mon Nov 17, 2008 5:36 am Post subject: |
|
|
When I type RETP I found only the valid command entered, But I am not sure why this error is coming to me. |
|
Back to top |
|
 |
warp5 Intermediate

Joined: 02 Dec 2002 Posts: 429 Topics: 18 Location: Germany
|
Posted: Tue Nov 18, 2008 2:00 am Post subject: |
|
|
Why don't you just put a "trace r" statement before the view and then a "trace o" after the parse and observe where the problem is occuring? |
|
Back to top |
|
 |
vijay_pampana Beginner
Joined: 11 Nov 2008 Posts: 9 Topics: 2
|
Posted: Tue Nov 18, 2008 5:41 am Post subject: |
|
|
Hi Warp5,
I need to first come out of view mode to see what is problem is with rexx. I even tried with all the traces but they are only useful when you come back from view mode back to the rexx program. The problem here is, I am not able to come back to rexx program from jcl opened in the view mode.
Thanks
--Vijay |
|
Back to top |
|
 |
warp5 Intermediate

Joined: 02 Dec 2002 Posts: 429 Topics: 18 Location: Germany
|
Posted: Wed Nov 19, 2008 1:55 am Post subject: |
|
|
When you are in view mode and make any changes to the job being viewed you can only leave after entering cancel and then PF3 or PF3 and then Enter. This is the way view works. |
|
Back to top |
|
 |
Dibakar Advanced

Joined: 02 Dec 2002 Posts: 700 Topics: 63 Location: USA
|
Posted: Wed Nov 19, 2008 8:09 am Post subject: |
|
|
warp5,
I think Vijay knows that he has to cancel it, it seems he is getting problem with cancel command.
Diba |
|
Back to top |
|
 |
jim haire Beginner
Joined: 30 Dec 2002 Posts: 140 Topics: 40
|
Posted: Wed Nov 19, 2008 1:24 pm Post subject: |
|
|
When I am in view mode within a file and make a change, I could then submit a job.
However, View is not like Edit where you need to enter "cancel" so the changes don't take place. I believe you could code an ADDRESS ISREDIT followed by an "END" command (essentially a PF3) after you have left the dataset you are viewing. |
|
Back to top |
|
 |
|
|