And, *beware if you start using PIPE .. STATE with dirids in execs*. You
will automatically start discovering the world of CMS workunits, more
precise: the default workunit remaining active and many SFS related commands
that start failing. One needs to return to CMS Ready to make it all work
again.
Here the notes I keep around in a "model" file for REXX execs.
PIPE STATE fn ft dirid ! ... leaves workunit open if the file
is found. This then results in:
DMSQRQ1157E Work unit already active when atomic request...
Solution: commit the workunit. Example
'PIPE LITERAL T T .!STATE ISODATE!CONS'
call csl 'DMSCOMM RETC REAS'; say retc reas
'CMDCALL QUERY LIMITS *' /* Would fail without DMSCOMM*/
Similar, when a file is open and a workunit is active, some
cmds give: DMSQRQ1157E Work unit already active when atomic..
Solution: get a new workunit. Example
call csl 'DMSGETWU RETC REAS WID1' /* Get a workunit */
call csl 'DMSPUSWU RETC REAS WID1' /* Start using it */
'CMDCALL QUERY LIMITS *'
call csl 'DMSPOPWU RETC REAS' /* Use prev Wunit */
call csl 'DMSRETWU RETC REAS WID1' /* Delete new Wunit */
Above thus two possiblities. The first one - with the commit- is easy, but
are you sure your code can commit everything? So maybe the second is what
you need. The PIPE with the STATE would go at the QUERY LIMITS place.
Note: the CMDCALL is not related to this problem, but makes QUERY LIMITS
produce an errormessage even when running under ADDRESS COMMAND.
2011/8/18 Bruce Hayden <[email protected]>
> PIPE STATE can do it - but read the author's help about return codes.
>
> On Thu, Aug 18, 2011 at 3:14 PM, Frank M. Ramaekers
> <[email protected]> wrote:
> > Is there a way to test the existence of a file in a SFS directory w/o
> > first ACCESSing it?
> >
> >
> >
> > Frank M. Ramaekers Jr.
> >
> >
> >
> >
> >
> > Systems Programmer
> >
> > MCP, MCP+I, MCSE & RHCE
> >
> >
> >
> > American Income Life Insurance Co.
> >
> > Phone: (254)761-6649
> >
> >
> >
> > 1200 Wooded Acres Dr.
> >
> > Fax: (254)741-5777
> >
> >
> >
> > Waco, Texas 76701
> >
> >
> >
> >
> >
> >
> >
> >
> >
> >
> > _____________________________________________________
> > This message contains information which is privileged and confidential
> and is solely for the use of the
> > intended recipient. If you are not the intended recipient, be aware that
> any review, disclosure,
> > copying, distribution, or use of the contents of this message is strictly
> prohibited. If you have
> > received this in error, please destroy it immediately and notify us at
> [email protected].
> >
>
>
>
> --
> Bruce Hayden
> z/VM and Linux on System z ATS
> IBM, Endicott, NY
>
--
Kris Buelens,
IBM Belgium, VM customer support