Re: Inline Rexx in JCL?

2011-11-20 Thread Shmuel Metz (Seymour J.)
In
,
on 11/19/2011
   at 06:15 PM, Roger Bolan  said:

>Okay, so wouldn't a simple IEBGENER step first to copy the inline
>source code into a member followed by the IKJEFT01 step do the job.

It would do a job, but not the job that the OP requested. I'd probably
use IEBUPDTE rather than IEBGENER, but those scars have mostly healed.
 
-- 
 Shmuel (Seymour J.) Metz, SysProg and JOAT
 ISO position; see  
We don't care. We don't have to care, we're Congress.
(S877: The Shut up and Eat Your spam act of 2003)

--
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html


Re: Inline Rexx in JCL?

2011-11-19 Thread Roger Bolan
Okay, so wouldn't a simple IEBGENER step first to copy the inline source
code into a member followed by the IKJEFT01 step do the job.
--Roger

On Fri, Nov 18, 2011 at 9:40 AM, Shmuel Metz (Seymour J.) <
shmuel+ibm-m...@patriot.net> wrote:

> In
> ,
> on 11/17/2011
>   at 03:00 PM, Roger Bolan  said:
>
> >This worked just fine a minute ago for me.
>
> It is not inline.
>
> --
> Shmuel (Seymour J.) Metz, SysProg and JOAT
> ISO position; see 
> We don't care. We don't have to care, we're Congress.
> (S877: The Shut up and Eat Your spam act of 2003)
>
> --
> For IBM-MAIN subscribe / signoff / archive access instructions,
> send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO
> Search the archives at http://bama.ua.edu/archives/ibm-main.html
>

--
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html


Re: Inline Rexx in JCL?

2011-11-19 Thread Shmuel Metz (Seymour J.)
In
,
on 11/17/2011
   at 03:00 PM, Roger Bolan  said:

>This worked just fine a minute ago for me.

It is not inline.
 
-- 
 Shmuel (Seymour J.) Metz, SysProg and JOAT
 ISO position; see  
We don't care. We don't have to care, we're Congress.
(S877: The Shut up and Eat Your spam act of 2003)

--
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html


Re: Inline Rexx in JCL?

2011-11-18 Thread Donald Johnson
It was passed on to me some time ago, so I can't attest to its longevity,
sorry!
*don*

On Fri, Nov 18, 2011 at 10:19 AM, Paul Gilmartin wrote:

> On Fri, 18 Nov 2011 08:35:50 -0500, Donald Johnson wrote:
>
> >Here is one alternative...Incidentally, you don't need the DD DATA if you
> >start the /* REXX */ comment in a column other than 1.
> >*don*
> >
> >//*
> >//* This JCL demonstrates how to create and execute an in-stream
> >//* REXX procedure. The PARM field contains only a single x'00'.
> >//*
> >//STEP0020  EXEC  PGM=IRXJCL,PARM=' '
> >//SYSTSPRT  DD  SYSOUT=*
> >//SYSTSIN   DD  DUMMY
> >//SYSEXEC   DD  *
> >say "Hello world! Date = "date()", time = "time()
> >EXIT
> >
> As I posted earlier, I was familiar with this behavior.  Is it GUPI,
> or is it undocumented, unsupported, and subject to change without
> notice?
>
> -- gil
>
> --
> For IBM-MAIN subscribe / signoff / archive access instructions,
> send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO
> Search the archives at http://bama.ua.edu/archives/ibm-main.html
>

--
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html


Re: Inline Rexx in JCL?

2011-11-18 Thread Paul Gilmartin
On Fri, 18 Nov 2011 08:35:50 -0500, Donald Johnson wrote:

>Here is one alternative...Incidentally, you don't need the DD DATA if you
>start the /* REXX */ comment in a column other than 1.
>*don*
>
>//*
>//* This JCL demonstrates how to create and execute an in-stream
>//* REXX procedure. The PARM field contains only a single x'00'.
>//*
>//STEP0020  EXEC  PGM=IRXJCL,PARM=' '
>//SYSTSPRT  DD  SYSOUT=*
>//SYSTSIN   DD  DUMMY
>//SYSEXEC   DD  *
>say "Hello world! Date = "date()", time = "time()
>EXIT
> 
As I posted earlier, I was familiar with this behavior.  Is it GUPI,
or is it undocumented, unsupported, and subject to change without
notice?

-- gil

--
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html


Re: Inline Rexx in JCL?

2011-11-18 Thread Phil Smith III
So it appears the app that's calling the EXEC as an exit is doing some magic
of its own, I guess, since it works without the IRXJCL hack. And I didn't
post the example because it's called as an exit and thus it didn't seem
relevant (although if I had, y'all would have surely seen the dumb error I'd
made!). But I still appreciate the various advice.

...phsiii

P.S. Yes, UrbanDictionary is correct. Though that was part of my vocabulary
long before UD existed.

--
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html


Re: Inline Rexx in JCL?

2011-11-18 Thread Donald Johnson
Here is one alternative...Incidentally, you don't need the DD DATA if you
start the /* REXX */ comment in a column other than 1.
*don*

//*
//* This JCL demonstrates how to create and execute an in-stream
//* REXX procedure. The PARM field contains only a single x'00'.
//*
//STEP0020  EXEC  PGM=IRXJCL,PARM=' '
//SYSTSPRT  DD  SYSOUT=*
//SYSTSIN   DD  DUMMY
//SYSEXEC   DD  *
say "Hello world! Date = "date()", time = "time()
EXIT
/*
//*

If you don't want to use IRXJCL, but want to use TSO instead, you can do
something like this:
//*
//* This JCL demonstrates how to create and execute an in-stream
//* REXX procedure.
//*
//STEP0020  EXEC  PGM=IKJEFT1B
//SYSEXEC   DD  UNIT=SYSALLDA,SPACE=(80,(5,1)),
//  DSN=&SYSEXEC,
//  AVGREC=K,DSNTYPE=LIBRARY,
//  RECFM=FB,LRECL=80,DSORG=PO
//SYSUT2DD  DISP=(OLD,PASS),VOL=REF=*.SYSEXEC,
//  DSN=&SYSEXEC(REXXSAMP)
//SYSIN DD  *
  /* REXX */
say "Hello world! Date = "date()", time = "time()
EXIT
/*
//*
//SYSTSPRT  DD  SYSOUT=*
//SYSTSIN   DD  *
 REPRO INFILE(SYSIN) OUTFILE(SYSUT2)
 %REXXSAMP
//*

And this is another, slightly more formal way:
//* -+-+-+-+-+-C-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-7--
//*  STEP NAME - #01UPDTE - EXECUTE  PGM - IEBUPDTE-
//*  FUNCTION  - CREATES TEMPORARY PDS FOR REXX PROGRAM-
//*  RESTART   - RERUN FROM THE BEGINNING WITH NO CHANGES  -
//* -+-+-+-+-+-C-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-7--
//#01UPDTE  EXEC  PGM=IEBUPDTE,PARM=NEW
//SYSPRINT  DD DUMMY
//SYSUT2DD DISP=(,PASS),UNIT=SYSDA,SPACE=(TRK,(5,1,1)),
// RECFM=FB,LRECL=80,BLKSIZE=0,DSORG=PO
//SYSIN DD *
./ ADD NAME=REXXSAMP
  /* REXX */
say "Hello world! Date = "date()", time = "time()
EXIT
/*
//*
//* -+-+-+-+-+-C-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-7--
//*  STEP NAME - #02REXX  - EXECUTE  PGM - IKJEFT1B-
//*  FUNCTION  - RUNS BATCH TSO COMMAND TO EXECUTE ABOVE REXX PROGRAM  -
//*  RESTART   - RERUN FROM THE BEGINNING WITH NO CHANGES  -
//* -+-+-+-+-+-C-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-7--
//#02REXX   EXEC  PGM=IKJEFT1B,PARM='%REXXSAMP',COND=(0,NE)
//SYSPROC   DD  DSN=*.#01UPDTE.SYSUT2,DISP=(OLD,DELETE)
//SYSTSPRT  DD  SYSOUT=*
//SYSTSIN   DD  DUMMY

Hopefully these will help you...

--
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html


Re: Inline Rexx in JCL?

2011-11-17 Thread Paul Gilmartin
On Thu, 17 Nov 2011 16:47:04 -0800, Ed Gould wrote:
> 
> Instead of DD asterisks,DATA equal sign @@
> Don't you mean  DD DATA,DLM equal sign @@

I agree.   I was in a hurry and didn't check his syntax; I understood
his intent.

> Sorry the damn keyboard doesn't allow the equal sign

I'm 99 44/100 % sure that it's not the keyboard, but some silly-assed
mail agent software downstream.  Apparently it isn't happy with
apostrophes also.

-- gil

--
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html


Re: Inline Rexx in JCL?

2011-11-17 Thread Paul Gilmartin
On Thu, 17 Nov 2011 18:20:34 -0600, Mike Schwab wrote:
> 
>//DD *,DATA=@@
>/* REXX */
>...
>@@
>should work.
> 
I fully agree.  I do something similar regularly.  But in this case, I
wasn't the owner of the JCL, so I wasn't at liberty to change it.

-- gil

--
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html


Re: Inline Rexx in JCL?

2011-11-17 Thread Ed Gould
 Mike,
Instead of DD asterisks,DATA equal sign @@
 Don't you mean  DD DATA,DLM equal sign @@

Sorry the damn keyboard doesn't allow the equal sign

Ed



--
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html


Re: Inline Rexx in JCL?

2011-11-17 Thread Mike Schwab
On Thu, Nov 17, 2011 at 5:03 PM, Paul Gilmartin  wrote:

> On Thu, 17 Nov 2011 17:33:31 -0500, Phil Smith III wrote:
>
>>And you don't even need the leading /* REXX */ on the Rexx, which avoids
>>some hassles with EOD.
>>
> Depends.  You still need it in SYSPROC.  But you can indent to avoid the
> EOD hassles.  I once ported an EXEC with "  /* REXX */" so indented to
> z/OS UNIX (USS).  Apparently USS is intolerant of the indention.  PMR
> resulted in a convoluted explanation of the logic, but no resolution.
> Apparently the rule is that a sufficiently detailed explanation of the
> misbehavior should be interpreted as WAD.
>
//DD *,DATA=@@
/* REXX */
...
@@
should work.
-- 
Mike A Schwab, Springfield IL USA
Where do Forest Rangers go to get away from it all?

--
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html


Re: Inline Rexx in JCL?

2011-11-17 Thread Paul Gilmartin
On Thu, 17 Nov 2011 17:26:32 -0500, Phil Smith III wrote:

>JFC. Looking at it for the 10,000 time, I realized I had another DD
>statement between the //SYSEXEC DD * and the Rexx code. What a maroon.
>
Do I find the correct expansion of the TLA in the Urban Dictionary?

>Thanks for trying it, Roger, and thanks to Alan Starr for his off-list
>suggestions. It was when I went to change to a standalone, non-PO Rexx
>program as a test that I realized my error. (And no, Rexx doesn't have to be
>PO.)
>
You mean that works nowadays!?  (I haven't  tried it lately.)  Didn't used to.
Can you humor me with a short example?

On Thu, 17 Nov 2011 17:33:31 -0500, Phil Smith III wrote:

>And you don't even need the leading /* REXX */ on the Rexx, which avoids
>some hassles with EOD.
>
Depends.  You still need it in SYSPROC.  But you can indent to avoid the
EOD hassles.  I once ported an EXEC with "  /* REXX */" so indented to
z/OS UNIX (USS).  Apparently USS is intolerant of the indention.  PMR
resulted in a convoluted explanation of the logic, but no resolution.
Apparently the rule is that a sufficiently detailed explanation of the
misbehavior should be interpreted as WAD.

On Thu, 17 Nov 2011 16:29:10 -0600, Jonathan Goossen wrote:
>
>I haven't done it, but you might be able to invoke edit to IKJEFT01 to put
>the code into a defaulted member of the library attached to the SYSEXEC.
>It would take one member of a library, but the code executed could be
>changed with each run.
>
I have on occasion supplied one or more Rexx EXECs instream and begun
my SYSTSIN with REPRO statements to copy each to a member of SYSEXEC
allocated as a temporary PDS.

--gil

--
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html


Re: Inline Rexx in JCL?

2011-11-17 Thread Paul Gilmartin
On Thu, 17 Nov 2011 15:00:36 -0700, Roger Bolan wrote:

>This worked just fine a minute ago for me.  LEVEL is a REXX exec in my
>CLIST library:
>

>On Thu, Nov 17, 2011 at 2:50 PM, Phil Smith III wrote:
>
>> Anyone ever gotten inline Rexx to work from JCL? 
>>
Perhaps if you had given the OP's question even a cursory reading,
you would have noticed "inline" both in the Subject: and in the
body which you quoted.  I suspect the JCL manuals contain ample
descriptions of what "inline" means (although they may use "instream"
instead, which I suppose might excuse your misunderstanding).

(Of course, the OP could have helped you by supplying his example.)

-- gil

--
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html


Re: Inline Rexx in JCL?

2011-11-17 Thread Paul Gilmartin
On Thu, 17 Nov 2011 16:50:45 -0500, Phil Smith III  wrote:

>Anyone ever gotten inline Rexx to work from JCL? I have a program that
>invokes a Rexx exit, but the exit is so simple that it seems like I should
>be able to just do a //SYSEXEC DD * and go from there. Alas, I get:
>
>IRX0110I The REXX exec cannot be interpreted.
>
>IRX0112I The REXX exec cannot be loaded.
>
>(in that order, which is interesting). The IRXLOAD seems to get RC=0, but
>the first call to the exit (IRXEXEC) gets RC=20.
>
>Am I missing something obvious?
> 
Yes.  You're not allowed to do that.  Sucks, since the API to Rexx supports
either PDS members or PS data sets.

Are you using IRXJCL or IKJEFT??

Someone has reported a hack; apparently an unintended but sometimes
useful behavior.  If you supply:

//STEP  EXEC  PGM=IRXJCL,PARM='x arg1 ...'

(but you need to put actual NULs in the PARM with, e.g. PDF "HEX ON")
the JFCB (whatever) will contain zero in the member field, and SYSEXEC
will be opened as sequential.

Such a kludge should be neither tolerated nor required.

YMMV,
gil

--
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html


Re: Inline Rexx in JCL?

2011-11-17 Thread Phil Smith III
And you don't even need the leading /* REXX */ on the Rexx, which avoids
some hassles with EOD.

--
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html


Re: Inline Rexx in JCL?

2011-11-17 Thread Jonathan Goossen
SYSEXEC is supposed to be a concatenation of libraries. The best that I 
can think of is something that I have done in other contexts. Put a step 
in front of it that copies the REXX statements into a temporary library.

I haven't done it, but you might be able to invoke edit to IKJEFT01 to put 
the code into a defaulted member of the library attached to the SYSEXEC. 
It would take one member of a library, but the code executed could be 
changed with each run.

Thank you and have a Terrific day!

Jonathan Goossen, ACG, CL
Tape Specialist
ACT Mainframe Storage Group
Personal: 651-361-4541
Department Support Line: 651-361-
For help with communication and leadership skills checkout Woodwinds 
Toastmasters



IBM Mainframe Discussion List  wrote on 11/17/2011 
03:50:45 PM:

> From: Phil Smith III 
> To: IBM-MAIN@bama.ua.edu
> Date: 11/17/2011 03:54 PM
> Subject: Inline Rexx in JCL?
> Sent by: IBM Mainframe Discussion List 
> 
> Anyone ever gotten inline Rexx to work from JCL? I have a program that
> invokes a Rexx exit, but the exit is so simple that it seems like I 
should
> be able to just do a //SYSEXEC DD * and go from there. Alas, I get:
> 
> IRX0110I The REXX exec cannot be interpreted. 
> 
> IRX0112I The REXX exec cannot be loaded.
> 
> (in that order, which is interesting). The IRXLOAD seems to get RC=0, 
but
> the first call to the exit (IRXEXEC) gets RC=20.
> 
> 
> 
> Am I missing something obvious?
> 
> 
> 
> Thanks,
> 
> .phsiii
> 
> 
> --
> For IBM-MAIN subscribe / signoff / archive access instructions,
> send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO
> Search the archives at http://bama.ua.edu/archives/ibm-main.html


This e-mail message and all attachments transmitted with it may
contain legally privileged and/or confidential information intended
solely for the use of the addressee(s). If the reader of this
message is not the intended recipient, you are hereby notified that
any reading, dissemination, distribution, copying, forwarding or
other use of this message or its attachments is strictly
prohibited. If you have received this message in error, please
notify the sender immediately and delete this message and all
copies and backups thereof. Thank you.

--
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html


Re: Inline Rexx in JCL?

2011-11-17 Thread Phil Smith III
JFC. Looking at it for the 10,000 time, I realized I had another DD
statement between the //SYSEXEC DD * and the Rexx code. What a maroon.

Thanks for trying it, Roger, and thanks to Alan Starr for his off-list
suggestions. It was when I went to change to a standalone, non-PO Rexx
program as a test that I realized my error. (And no, Rexx doesn't have to be
PO.)

-Original Message-
From: IBM Mainframe Discussion List [mailto:IBM-MAIN@bama.ua.edu] On Behalf
Of Phil Smith III
Sent: Thursday, November 17, 2011 1:51 PM
To: IBM-MAIN@bama.ua.edu
Subject: Inline Rexx in JCL?

Anyone ever gotten inline Rexx to work from JCL? I have a program that
invokes a Rexx exit, but the exit is so simple that it seems like I should
be able to just do a //SYSEXEC DD * and go from there. Alas, I get:

IRX0110I The REXX exec cannot be interpreted. 

IRX0112I The REXX exec cannot be loaded.

(in that order, which is interesting). The IRXLOAD seems to get RC=0, but
the first call to the exit (IRXEXEC) gets RC=20.

 

Am I missing something obvious?

 

Thanks,

.phsiii


--
For IBM-MAIN subscribe / signoff / archive access instructions, send email
to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the
archives at http://bama.ua.edu/archives/ibm-main.html

--
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html


Re: Inline Rexx in JCL?

2011-11-17 Thread Roger Bolan
This worked just fine a minute ago for me.  LEVEL is a REXX exec in my
CLIST library:
//TSO2 EXEC PGM=IKJEFT01,DYNAMNBR=200
//SYSPROC  DD  DISP=SHR,DSN=RBOLAN.MY.CLIST
// DD  DISP=SHR,DSN=TOOLS.CLIST.NEW
//SYSTSPRT DD  SYSOUT=*
//SYSABEND DD  SYSOUT=*
//SYSTSIN  DD  *
   PROFILE PREFIX(BOLAN)
   %LEVEL
/*

Regards,
--Roger

On Thu, Nov 17, 2011 at 2:50 PM, Phil Smith III  wrote:

> Anyone ever gotten inline Rexx to work from JCL? I have a program that
> invokes a Rexx exit, but the exit is so simple that it seems like I should
> be able to just do a //SYSEXEC DD * and go from there. Alas, I get:
>
> IRX0110I The REXX exec cannot be interpreted.
>
> IRX0112I The REXX exec cannot be loaded.
>
> (in that order, which is interesting). The IRXLOAD seems to get RC=0, but
> the first call to the exit (IRXEXEC) gets RC=20.
>
>
>
> Am I missing something obvious?
>
>
>
> Thanks,
>
> .phsiii
>
>
> --
> For IBM-MAIN subscribe / signoff / archive access instructions,
> send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO
> Search the archives at http://bama.ua.edu/archives/ibm-main.html
>

--
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html