English 中文(简体)
Is there a TSO command written in REXX or CLIST that can determine WHO has enqueued a dataset?
原标题:

I need to write a REXX Exec or Clist to identify WHO has enqueued a Dataset and display a user friendly message on an ISPF dialog application. Due to system configuration issues, the %WHOHAS command is not available. However I also know that ISPF itself (Option 3.4) has proprietary hooks into the zos mainframe to display the enqueued resource information I need - so the infomation can be obtained. Unfortunately I don t know how to access this data from outside ISPF 3.4 using a REXX Exec or CLIST. Any suggestions?

最佳回答

This turned out to be a very simple fix. Nothing fancy. If the clist uses CONTROL NOFLUSH it will not abort when the ALLOCation of a dataset fails. We also have a installed product called TSOPLUS that will format a message to the terminal identifying who has allocated a dataset when the allocation fails. By turning off FLUSH and then systrapping the TSOPLUS message, I was able to extract the information I needed.

问题回答

On first reading I thought this would be a pretty simple thing to dig up. Not quite!

Under ISPF you can get a panel to display who is holding a dataset by typing the following on the command line:

TSO ISRDDN ENQ Dataset-name

The ISRDDN command is documented at: http://publibz.boulder.ibm.com/cgi-bin/bookmgr/FRAMESET/ispzug50/G.0?ACTION=MATCHES&REQUEST=isrddn&TYPE=FUZZY&SHELF=ispzpm50&DT=20060621022939

Invoking ISRDDN is possible from within a REXX program but I don t know how to capture the output into a stem variable where you could parse it out and issue a message. I could not find a command line interface to ISRDDN that allows capture of the output.

There is another utiltiy at: http://www.sillysot.com/mvs/index.htm?queryenq.htm that claims to do this as well, I have never tried it so cannot comment any further on it.

I Googled your question and it looks like several people have used the MVS command

D GRS,RES=(*,dsname)
to determine who is holding a dataset. However, this requires console access so would not be appropriate for most users. If console access is allowed, then you could start a console session under REXX and capture the output fairly easily, see: http://www.redbooks.ibm.com/redbooks/pdfs/sg244626.pdf.

One final place to search would be the CBT tapes (freeware for IBM mainframes). Here you can find several implementations of the WHOHAS ISPF command.

Sorry, but this is the best I can do.





相关问题
How to read a PS file in reverse order?

I have a PS file to be read in reverse order and process accordingly. Do we have a way to mention to read the file in reverse order in FD in COBOL module? OR do we have something to achieve the same ...

Allocation of memory with LE routines

At Allocation of Memory in Variable-Length Tables NealB mentioned LE routines to allocate/deallocate memory in a non-CICS COBOL program. I d very much like to know how this is done: how the LE ...

How to pass arguments to REXX program through JCL

Can we pass arguments to a REXX program from JCL? I suppose, JCL PARM can be used as we use for passing arguments to COBOL programs.. Do put your ideas here...

How to write a HEX string into a file as HEX using REXX

I have a string RAJA which should be written into a file as HEX data. Here are sample codes which help me to describe the issue. Case(a) name = RAJA name = C2X(name) /* Hex value = 52414A41 *...

Start SQL Server Jobs when field = specific value

I don t know if this is even possible, so i would appreciate any ideas, even those outside of Sql Server 2005, on how this might be accomplished. I have a linked server set up to a remote mainframe ...

热门标签