Portal | IBM Manuals | Downloads | Products | Refer | Info | Programs | JCLs | Forum Rules*| Site Map | Mainframe CD 
IBMMAINFRAMES.com - IBM Mainframe Support Forums Index
 
Register
 
IBMMAINFRAMES.com - IBM Mainframe Support Forums Index FAQ Search Memberlist Usergroups Profile Log in to check your private messages Log in
 
Can we run REXX exec in spool
Goto page Previous  1, 2
 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> CLIST & REXX
Author Message
Pedro

Senior Member


Joined: 01 Sep 2006
Posts: 313
Location: work

PostPosted: Wed Jul 16, 2008 10:38 pm    Post subject: Reply to: Can we run REXX exec in spool
Reply with quote

Quote:
edit the datasets which are referred in the job

FYI. not the original quote, but what I gleaned from the posts.

coding:
1. write ISPF editor macro that uses CURSOR macro command to determine which line and which column the cursor is on.
2. Use LINE macro command to get the line.
3. use REXX parse instruction to isolate data at cursor location.
4. invoke EDIT service specifying dataset name.
5. put your code into SYSPROC concatenation.

setup:
1. enter SE line command in front of job to enter an editor session for the job output.
2. issue KEYS command.
3. set a PF key to issue your new program
4. PF3 to exit KEYS panel

usage:
1. enter SE line command in front of job to enter an editor session for the job output.
2. put cursor on dataset name
3. press your changed PF key.
Back to top
View user's profile Send private message
References
PostPosted: Wed Jul 16, 2008 10:38 pm    Post subject: Re: Reply to: Can we run REXX exec in spool Reply with quote

krsk

New User


Joined: 24 Jun 2008
Posts: 16
Location: INDIA

PostPosted: Thu Jul 17, 2008 3:35 pm    Post subject:
Reply with quote

Hello

Pedro's reply exactly points to the answer of the problem. icon_smile.gif

But, I would like to know where to issue the keys command? It does not work in the command input line in the screen which we get by issuing se infront of the job.

Thanking you,
[/quote]
Back to top
View user's profile Send private message
krsk

New User


Joined: 24 Jun 2008
Posts: 16
Location: INDIA

PostPosted: Thu Jul 17, 2008 3:43 pm    Post subject:
Reply with quote

Hello,

Quote:
what business reason is there to do this?

Suppose we submit a jcl, in which we have many dsns. If any error occurs while submitting that jcl, we can go to spool and understand the reasons. The the jcl used is in JESJCL. Now, suppose editing, or browsing one of the datasets refferred by the jcl becomes necessary, then if we have some routines we can just place the cursor over dsn and run the routine, we can edit it, there itself.

I can site you one example. In this case I have written a COBOL program for writing data into a sequential file, the data is also given through the JCL. I submit the run jcl, the job is executed successfully. Now I want to see the file that is written. Now, suppose I am in the SPOOL, JESJCL, there I want to see the file. If I have one routine BD I can just place the cursor on the dsn and run the routine, the dataset gets opened there itself.

Thanking you,
Back to top
View user's profile Send private message
dick scherrer

Global Moderator


Joined: 23 Nov 2006
Posts: 7505
Location: 221 B Baker St

PostPosted: Thu Jul 17, 2008 7:23 pm    Post subject:
Reply with quote

Hello,

Quote:
I believe we understand what you want. . .
I surely missed this one. . . icon_sad.gif

Quote:
Now, suppose editing, or browsing one of the datasets refferred by the jcl becomes necessary,
Now, i believe i understand. . . Until now, i misunderstood that you wanted to actually edit the spool content rather than some dataset named in the spool content icon_redface.gif

Editing some dataset should not be an issue. . .

And, yes, i believe you would do well to proceed as Pedro suggested. You could issue the KEYS command on the ispf main menu and the "Keylist Utility" will be run and you can customize your pfk definitions.
Back to top
View user's profile Send private message
Pedro

Senior Member


Joined: 01 Sep 2006
Posts: 313
Location: work

PostPosted: Thu Jul 17, 2008 9:26 pm    Post subject: Reply to: Can we run REXX exec in spool
Reply with quote

Quote:
You could issue the KEYS command on the ispf main menu and the "Keylist Utility" will be run and you can customize your pfk definitions.

I think you get the wrong set of keys, doing it from the ISPF main menu.

In SDSF, after you type SE and press Enter, it should put you into the editor with your job output shown. In the ISPF command line, type KEYS. If that does not work, please explain what message you get.

You can also be anywhere within SDSF and type KEYLIST in the command line. Select ISFEDKEY to get the keys used by the SE edit session.
Back to top
View user's profile Send private message
krsk

New User


Joined: 24 Jun 2008
Posts: 16
Location: INDIA

PostPosted: Fri Jul 18, 2008 2:52 pm    Post subject:
Reply with quote

Hello,

Quote:
In SDSF, after you type SE and press Enter, it should put you into the editor with your job output shown. In the ISPF command line, type KEYS. If that does not work, please explain what message you get.

I went to SDSF, by using TSO SDSSF ST, I typed SE infront of the job and then, in the command line I typed KEYS. It is showing invalid command.

Thanking you,
Back to top
View user's profile Send private message
enrico-sorichetti

Global Moderator


Joined: 14 Mar 2007
Posts: 2560
Location: italy

PostPosted: Fri Jul 18, 2008 3:05 pm    Post subject: Reply to: Can we run REXX exec in spool
Reply with quote

Quote:
I went to SDSF, by using TSO SDSSF ST, I typed SE infront of the job and then, in the command line I typed KEYS. It is showing invalid command.


you did not enter the ispf sdsf application
You used the sdsf tso command with its builtin display logic
You should have noticed that by entering se, You did not get an edit session
but a browse session of the jes dataset ( tested )

if You enter the sdsf application thru the ISPF interface all the ISPF facilities will be available ( tested )
Back to top
View user's profile Send private message
Pedro

Senior Member


Joined: 01 Sep 2006
Posts: 313
Location: work

PostPosted: Fri Jul 18, 2008 9:35 pm    Post subject: Reply to: Can we run REXX exec in spool
Reply with quote

Their is usually a local menu panel that is used to call SDSF.

Or you could use an (untested) exec like this:
Code:
/* rexx */  Parse arg option
Address ISPEXEC "SELECT PGM(ISFISP) NEWAPPL(ISF) PARM("option")"
Back to top
View user's profile Send private message
Josh Keller

New User


Joined: 08 Oct 2007
Posts: 7
Location: Columbia, SC

PostPosted: Fri Jul 18, 2008 9:53 pm    Post subject: Re: Reply to: Can we run REXX exec in spool
Reply with quote

Pedro wrote:

coding:
1. write ISPF editor macro that uses CURSOR macro command to determine which line and which column the cursor is on.
2. Use LINE macro command to get the line.


Just as an FYI (and some probably already know), you can use ZSCREENI variable to obtain text from the screen rather than limiting to just an Edit Macro LINE command.


Code:

"ISPEXEC VGET (ZSCREENI,ZSCREENC,ZSCREENW)"
ZSCREENC = ZSCREENC + 1
ROW=(ZSCREENC)%ZSCREENW
COL=ZSCREENC - (ZSCREENW*ROW)
ROW = ROW + 0

IF COL <= 0 THEN ROW = ROW -1
LINETEXT=SUBSTR(ZSCREENI,((ROW*ZSCREENW)+1),ZSCREENW)


Then you can parse LINETEXT to pull out the DSN and use Pedro's instructions to set it up. This would allow you to pull the DSN out while viewing JESJCL for example, and you don't need an edit session.
Back to top
View user's profile Send private message
krsk

New User


Joined: 24 Jun 2008
Posts: 16
Location: INDIA

PostPosted: Wed Jul 23, 2008 5:00 pm    Post subject:
Reply with quote

Hello,

Yeah! I got the answer to the problem. Like Pedo said, in SDSF(entered through the menu option), we can use the same rexx routine for editing the datasets.

Thanking you,
Back to top
View user's profile Send private message
dick scherrer

Global Moderator


Joined: 23 Nov 2006
Posts: 7505
Location: 221 B Baker St

PostPosted: Wed Jul 23, 2008 8:23 pm    Post subject: Reply to: Can we run REXX exec in spool
Reply with quote

Hello KRSK,

Thank you for letting us know you have a solution icon_smile.gif

d
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> CLIST & REXX All times are GMT + 6 HoursGoto page Previous  1, 2
Page 2 of 2