On Wed, 20 Jun 2012 10:58:31 -0500, McKown, John wrote:
>
>Easier for me to write I/O exits than to set up and allocate the pipes to
>SYSIN and SYSPRINT. Yes, I guess that I could have used pipes. But it is
>simplier FOR ME to use I/O exits. Especially in HLASM. Remember that I don't
>have a C compiler.
>
I tried the following:
/* Rexx */ signal on novalue; /*
Doc: wrapper for IDCAMS.
*/
trace R
address 'MVS'
'REXXRC' BPXWDYN( 'alloc dd(SYSIN) path(''/dev/fd/0'') filedata(TEXT)' ,
'recfm(F) lrecl(80) reuse msg(WTP)' )
/* Does not work. */
'REXXRC' BPXWDYN( 'alloc dd(SYSPRINT) path(''/dev/fd/1'') filedata(TEXT)' ,
'recfm(V,B,A) lrecl(125) reuse msg(WTP)' )
/* Works. */
'REXXRC' BPXWDYN( 'alloc dd(SYSPRINT) sysout(R) reuse msg(WTP)' )
address 'ATTCHMVS' 'IDCAMS'
exit( RC )
It successfully processes commands from stdin. It writes to SYSOUT,
but if I try to write to stdout, I get:
10.11.33 STC07914 +IDC4999I UABORT CODE 32
M&C tells me CODE 32 is attempt to access unopened data set.
It would sure be nice if IDC4999I gave me the DDNAME.
When I end SYSIN/stdin with "^D", I get:
IDC3003I FUNCTION TERMINATED. CONDITION CODE IS 12
I wonder why.
As a point of reference, I tried running some dusty JCL that
execs IDCAMS and issues a LISTDS command. Doesn't
work now. Did it ever work, or did I archive some bad JCL?
And, of course, I haven't addressed the APF concerns.
-- gil
----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [email protected] with the message: INFO IBM-MAIN