We have a prototype for a z/OS Unix shell command wrapper for IAZSYMBL.
 The envisioned use of this would be to be able to integrate JCL/System
symbols with z/OS shell scripts.

I was hoping to solicit your opinions:
  - would this be useful? What are interesting use cases?
  - suggestions for improvement

This would be a command that we would plan on making available free as a
new command in the Co:Z Toolkit.

Kirk Wolf
Dovetailed Technologies
http://dovetail.com

(*Note*: in the following examples, shell input is bold and follows "> ".
 Also: you need  "set -o pipecurrent" when piping jessym output into "read"
or "." )

Here's the proposed syntax:

*> jessym  *
usage: jessym name
   or: jessym [-p <prefix>] -s name-pattern ...
   or: jessym [-p <prefix>] -x name-pattern ...
   or: jessym [-r] -c name=value ...
   or: jessym -u name=value ...
   or: jessym -d name-pattern ...

*Form 1: Display the value of a single variable:*

*> jessym A*
B

*> set -o pipecurrent *
*> jessym A | read -r myvar*
*> echo $myvar*
B

*Form 2: Show variables matching patterns:*

*> jessym -s SYS* *

SYS_CORR_CURRJOB='S0000434DTLZOS01CC27C5EA.......:
       '

(no pattern defaults to "*") -
*> jessym -s*
SYS_CORR_CURRJOB='S0000434DTLZOS01CC27C5EA.......:
       '
A='B'

*> jessym -s | . /dev/fd0*
*> echo $SYS_CORR_CURRJOB*
S0000434DTLZOS01CC27C5EA.......:

*Form 3: Show variables (with exports) matching patterns:*

*> jessym -x*
export SYS_CORR_CURRJOB='S0000434DTLZOS01CC27C5EA.......:
             '
export A='B'

*> jessym -p JES_ -x | . /dev/fd0*
*> echo $JES_A*
B

*Form 4: Create a new JES System Symbol:*

*> jessym -c C=abc*
*> jessym C*
abc

*> jessym -c C=abc*

JesSymbols[W]: IAZSYMBOL rc=0 RET=4 REAS=28

(create with replace option:)

*> jessym -rc C=def*
*> jessym C*
def

*Form 5: Update an existing symbol:*
*> jessym -u C=ghi*
*> jessym C*
ghi
*> jessym -u X=yyy*
JesSymbols[W]: IAZSYMBOL rc=0 RET=4 REAS=4

*Form 6: Delete symbols:*
*> jessym -d C*
*> jessym -d A**
*> jessym -d FOO*
JesSymbols[W]: IAZSYMBOL rc=0 RET=4 REAS=4

*Submitting JCL from a shell script using symbols:*

Since the z/OS Unix "submit" command (or TSO submit!) doesn't support
passing JES symbols into the internal reader, we plan on enhancing the Co:Z
"todsn" command to allow this, perhaps something like:

*> fromdsn "//my.jcl(xxx)" | *
*     todsn -x "sysout(a) symlist(*)" //INTRDR*


*Automatic invocation under COZBATCH*

We will probably enhance COZBATCH so that all symbols are exported with
"JES_" prefixes before your shell or program is started.  Opinions?

----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN

Reply via email to