Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

problem with changing data

Status
Not open for further replies.

janegee

Programmer
Mar 16, 2003
4
US
Somehow I cannot get data to insert using the below REX exec. I know it must be something simple, all I am trying to do it take a line of data that already has text in it and add some addition text on the line. Can anyone help me out.

ADDRESS TSO
"ALLOC FI($TMP) DA('xxx.xxxx.xxxx.xxx)') SHR REUSE"
"NEWSTACK"
"EXECIO * DISKR $TMP (FINIS)"
ISREDIT C ' ' 'test' 1 4 ALL
"EXECIO" QUEUED() "DISKW $TMP (FINIS)"
"DELSTACK"
"FREE FI($TMP)"
 
When I encountered a similar probelm I created an edit macro with the change in it and then used:

address ISPEXEC "EDIT DATASET('"ztempf"') MACRO(mymacro)"

the 'mymacro' looked like this:

/* REXX */
"ISREDIT MACRO"
ADDRESS ISPEXEC "VGET (ZTEMPF)"
SYSUID = USERID()
TRAPON=OUTTRAP('ON')
"ISREDIT C 'CS01' 'CS05' ALL"
"ISREDIT C '"SYSUID||"01' '"SYSUID||"05' ALL"
"ISREDIT RESET"
"ISREDIT SAVE"

Not sure if this helps, but it definately has the desired effect.
 
Where does the macro reside. I am defintely doing something wrong since when I execute it, as is, it cannot find the macro. How do I reference it in the same rexx exec? Thanks so much!
 
The original code uses EXECIO to load the queue. The ISREDIT CHANGE cannot hit this data; you must be in ISPF Edit for that.

Try something like
Code:
do queued()
   pull front 5 data
   if front = "" then front = "TEST"
   queue front||data
end   /* queued */
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top