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
 

 

Can we run REXX exec in spool
Goto page 1, 2  Next
 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> CLIST & REXX
View previous topic :: :: View next topic  
Author Message
krsk

New User


Joined: 24 Jun 2008
Posts: 23
Location: INDIA

PostPosted: Fri Jul 11, 2008 5:13 pm    Post subject: Can we run REXX exec in spool
Reply with quote

Hello

Can we run REXX exec in spool? Suppose I have one exec DE for deleting a dataset, I have to use it for deleting the datasets in one of the jobs in the spool.

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

expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8593
Location: Back in jolly old England

PostPosted: Fri Jul 11, 2008 5:20 pm    Post subject:
Reply with quote

How do you mean run it in the spool ?

Do you perhaps mean to process JES elements ?
Back to top
View user's profile Send private message
krsk

New User


Joined: 24 Jun 2008
Posts: 23
Location: INDIA

PostPosted: Fri Jul 11, 2008 6:39 pm    Post subject:
Reply with quote

Hello

It is like this, see if we have some job submitted like USERIDA, when we go into that, using ? in the left of jobname in the spool, then it displays some datasets, if we press s we can browse them. In the same way, I want a REXX program DE if I type DE instead of S, it should be deleted. Is it possible with REXX and ISPF in the spool?

I am new to REXX, so I do not have much idea on REXX.

Thanking you,
Back to top
View user's profile Send private message
Garry Carroll

Active Member


Joined: 08 May 2006
Posts: 988
Location: Dublin, Ireland / Edinburgh, Scotland

PostPosted: Fri Jul 11, 2008 6:48 pm    Post subject:
Reply with quote

Quote:
using ? in the left of jobname in the spool, then it displays some datasets, if we press s we can browse them. In the same way, I want a REXX program DE if I type DE instead of S, it should be deleted


You want a function to delete selected spool files while is SDSF? If you display the job as (H)eld output and enter the ? You can then purge individual files.

Regards,
Garry.
Back to top
View user's profile Send private message
krsk

New User


Joined: 24 Jun 2008
Posts: 23
Location: INDIA

PostPosted: Fri Jul 11, 2008 7:02 pm    Post subject:
Reply with quote

Hello,

Yeah, but I want to develop my own REXX routine, I want to do some other programs also for renaming the files in spool etc.

Thanking you,
Back to top
View user's profile Send private message
Bill Dennis

Active Member


Joined: 17 Aug 2007
Posts: 562
Location: Iowa, USA

PostPosted: Fri Jul 11, 2008 7:13 pm    Post subject:
Reply with quote

The names you see when you do a '?' by a job are the DDNAMEs that created the spool output. You cannot change these names.

If you select output for viewing using the 'SE' command, you'll be in an EDIT window. You could use EDIT macros written in REXX to act upon dataset names found in the output.
Back to top
View user's profile Send private message
krsk

New User


Joined: 24 Jun 2008
Posts: 23
Location: INDIA

PostPosted: Mon Jul 14, 2008 11:34 am    Post subject:
Reply with quote

Hello,

Yeah! That is right. Renaming the files in the SPOOL is not possible.

I gave that by mistake, I wanted to mean an example.

The requirement is, I want to create my own REXX routines, for editing, browsing, deleting etc the files in SPOOL job, and I want to know how I can run it in SPOOL.

Thanking you,
Back to top
View user's profile Send private message
Garry Carroll

Active Member


Joined: 08 May 2006
Posts: 988
Location: Dublin, Ireland / Edinburgh, Scotland

PostPosted: Mon Jul 14, 2008 1:19 pm    Post subject:
Reply with quote

Quote:
I want to create my own REXX routines, for editing, browsing, deleting etc the files in SPOOL job


It's unclear what precisely you want to do. Do you want the ability to manipulate the contents of SPOOL datasets (e.g. JESYSMSG, SYSPRINT &c.) or do you want to manipulate selected datasets that were used by the job during execution?

If the former, I'd expect that your security people would have a view on this as you would be attempting to alter the jobs' history. If the latter, you can use IBM's SDSF Support for REXX or else interface with the SDSF program by providing the ISFIN and ISFOUT and linking to SDSF.


Quote:
I want to know how I can run it in SPOOL.


You can't run in IN spool. Spool is data, not an environment. You can run your REXX to use the spool data.


Regards,
Garry.
Back to top
View user's profile Send private message
krsk

New User


Joined: 24 Jun 2008
Posts: 23
Location: INDIA

PostPosted: Mon Jul 14, 2008 7:41 pm    Post subject:
Reply with quote

Hello,

The actual requirement is, I want to develop a REXX routine DS – Delete dataset, place the cursor on the dataset of the Job and the dataset should get deleted. Like this I want some more routines like, ED - edit dataset, BD - Browse dataset, LM - list the members in the PDS in the JOB, etc.

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

Global Moderator


Joined: 14 Mar 2007
Posts: 10201
Location: italy

PostPosted: Mon Jul 14, 2008 7:55 pm    Post subject: Reply to: Can we run REXX exec in spool
Reply with quote

Quote:
I am new to REXX, so I do not have much idea on REXX.

developing tools is not something easy if You do not have an idea of ...
also the whole set of questions did not clarify at all Your needs,
maybe they were clear to You but You were not able to extend this clarity around ...

Quote:
The actual requirement is, I want to develop a REXX routine DS

is that a requirement or a whim..... looks more like the second icon_confused.gif

also the issue is not at all spool, or anything similar related

is just a simple cursor driven data extraction from any ispf like panel
position the cursor on something that looks like a dataset name and,
hitting the proper function key perform some action

the issue has been debated with dubious results many many times
as a hint search the net for the vcursor snippet from Doug Nadel
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: Mon Jul 14, 2008 10:04 pm    Post subject:
Reply with quote

Hello,

Quote:
Like this I want some more routines like, ED - edit dataset, BD - Browse dataset, LM - list the members in the PDS in the JOB, etc.
Keep in mind that the spool is not at all like a pds and cannot be accessed the same ways.

Quote:
The actual requirement is, I want to develop a REXX routine DS
Who determined this requirement (and the others you mentioned)? What business reason is there for this?

Spool entries should be looked at, possibly printed, and deleted - there should be no editing of spool entries. . .
Back to top
View user's profile Send private message
Anuj Dhawan

Senior Member


Joined: 22 Apr 2006
Posts: 6258
Location: Mumbai, India

PostPosted: Tue Jul 15, 2008 12:02 pm    Post subject:
Reply with quote

dick scherrer wrote:
Spool entries should be looked at, possibly printed, and deleted - there should be no editing of spool entries. . .
Yup they are to check the status of some "run"..otherwise why IBM licensed program has been given a name "System Display And Search Facility", they could have done with it by something like SDEF - "System Data And Edit Facility" .. icon_biggrin.gif


P.S.: Sorry, I know my reply in this thread is just 'stupid' but it's one of the most ambitious (weird actually) requirement I've ever come across..or perhaps the explanation from the OP is not that well constructed..
Back to top
View user's profile Send private message
krsk

New User


Joined: 24 Jun 2008
Posts: 23
Location: INDIA

PostPosted: Wed Jul 16, 2008 10:54 am    Post subject:
Reply with quote

Hello,

Sorry for being not able to describe the problem in the way everyone can understand......

Let me explain the problem once again.

See I have a REXX routine ED, for editing the dataset. What it does is, when I open some datasets like JCLs, which contain the names of other datasets in them, when I type ED in command line and place the cursor on the dataset name, that dataset gets opened in edit mode.

Now, I want a REXX routine, with which I can edit the datasets which are referred in the SPOOL outputs like JESJCL. How can it be done?

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

Senior Member


Joined: 28 Jul 2006
Posts: 1703
Location: Australia

PostPosted: Wed Jul 16, 2008 12:28 pm    Post subject:
Reply with quote

Hi,

Bill mentioned it earlier, rather than selecting the job with an S, select it with SE, this will put you in EDIT mode and you should be able to use your MACROes.


Gerry
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: Wed Jul 16, 2008 8:52 pm    Post subject:
Reply with quote

Hello,

Quote:
Now, I want a REXX routine, with which I can edit the datasets which are referred in the SPOOL outputs like JESJCL. How can it be done?
I believe we understand what you want. . . I also believe you cannot get what you say you want. . . .

Editing implies change. Data already spooled will not be changed by an editing session. Even if you enter the editor, i believe the closest you could get to what you seem to want is to save a copy in some dataset.

As i asked earlier and you have not yet answered - what business reason is there to do this? If we understood why this is needed, we might be able to offer better suggestions.
Back to top
View user's profile Send private message
Pedro

Senior Member


Joined: 01 Sep 2006
Posts: 2019
Location: Silicon Valley

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
krsk

New User


Joined: 24 Jun 2008
Posts: 23
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: 23
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

Site Director


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

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: 2019
Location: Silicon Valley

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
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> CLIST & REXX All times are GMT + 6 Hours
Goto page 1, 2  Next
Page 1 of 2

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts What is the command to check MODE of ... rohanthengal CLIST & REXX 6 Fri Nov 18, 2016 1:48 pm
This topic is locked: you cannot edit posts or make replies. Rexx to create GDG by scanning JJ result krish.deepu CLIST & REXX 5 Tue Oct 25, 2016 5:32 pm
No new posts Replace repeated JCL with looping REXX prino CLIST & REXX 3 Thu Oct 13, 2016 5:30 am
This topic is locked: you cannot edit posts or make replies. Need to code a Rexx PGM sundaram.naveen CLIST & REXX 18 Thu Oct 06, 2016 6:45 pm
No new posts Strange EXEC function call in z/VM Willy Jensen CLIST & REXX 3 Wed Oct 05, 2016 2:07 pm


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