I'm trying to construct some modify commands in AF/Operator, unfortunately 
the product for which the commands are being issued requires single quotes 
around some operands... Here's what I did:

VARCMD1 = "F $SCHED,VAR(DB2TNAME,"||"''"||STRIP(DSN)||"'')" 
VARCMD2 = "F $SCHED,VAR(DB2TRBAS,"||"''"||STRIP(STARTRBA)||"'')"
VARCMD3 = "F $SCHED,VAR(DB2TRBAE,"||"''"||STRIP(ENDRBA)||"'')" 
"OPER '" VARCMD1 "'" 
"OPER '" VARCMD2 "'" 
"OPER '" VARCMD3 "'" 

Note the preponderance of double and single quotes (it may help to pull 
the text into ISPF to look at it).

The OPER command as I understand it, takes its operand within single 
apostrophes  (for a simple example - OPER 'D T' )
I need to issue the command F $SCHED,VAR(name, 'value') with the value in 
single apostrophes.
The above Rexx does it by using  quotes around literal strings, and double 
apostrophes when we want to end up with a single one in the final command.
The variables within the STRIP function are created in other parts of the 
Rexx code.

Is there an easier- to-maintain, more "elegant" way to do this?   The 
above code works, but I don't think it's easy to understand or maintain.


Tim Hare
Senior Systems Programmer
Florida Department of Transportation
(850) 414-4209

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

Reply via email to