1. Create a separate Rexx called MAGIC with the following contents:

address ISREDIT
"macro (dsn) NOPROCESS"
"CHANGE '@@@TDSN'" dsn
"SAVE"
"END"
exit

2. Invoke it like this:

TARGFILE = kuser".OUTPUT.txt"
EditMe = kuser".SAMPLE.PDS(MEM)" /* contains the string '@@@TDSN' */
address ISPEXEC
"edit dataset('"EditMe"') macro(magic) parm(TARGFILE)"
exit

Peter


On Wed, 30 Jul 2025 at 08:16, Paul Gilmartin <
[email protected]> wrote:

> On Tue, 29 Jul 2025 21:34:02 GMT, essteam wrote:
> >..
> >Im not well versed in Rexx -.
> >I need some assistance in using isredit to change a string of characters
> to another value -.
> >Can't seem to find a decent example -
>     ...
> >ADDRESS ISPEXEC
> > "isredit CHANGE '@@@TDSN' &TARGFILE"
> >
> I believe "&TARGFILE" is CLIST-Speak.
> but you might let Edit resolve the variable with:
>   "isredit CHANGE '@@@TDSN' (TARGFILE)"
> (Edit effectively quotes variable references; REXX needn't see them.)
>
> An expert would shorten:
>  ADDRESS ISPEXEC
>   "isredit ...
> to:
>  ADDRESS  isredit ...
>
> but as you did it, the second "ADDRESS ISPEXEC" is  superfluous;
> the first persists in effect.
>
> --
> gil
>
> ----------------------------------------------------------------------
> For IBM-MAIN subscribe / signoff / archive access instructions,
> send email to [email protected] with the message: INFO IBM-MAIN
>

----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [email protected] with the message: INFO IBM-MAIN

Reply via email to