Here’s an example of how I might do it.

/* REXX */                        
 arg ofile                         
 ofile = Strip(ofile,"B","'")      
 ocmd  = '$TOFFLOAD1,DSN='||ofile  
 Address TSO ocmd                  
 Exit                             

Chip

> On Feb 19, 2019, at 11:18 AM, Lizette Koehler <stars...@mindspring.com> wrote:
> 
> I would use SYMLIST LIST CONLIST in the CONTROL Statement
> 
> See what is setting the quotes in the &OFILE
> 
> Typically TSO CLIST is what you see is what you get (WYSISYG)
> 
> It does not typically add quotes
> 
> You can also use SHOWCMD ON in 3.4   See what ISPF might be doing
> 
> If ISPF is adding quotes - then you will need to strip off the quotes.
> 
> Any reason not to use REXX rather than CLIST?
> 
> 
> Lizette
> 
>> -----Original Message-----
>> From: IBM Mainframe Discussion List <IBM-MAIN@LISTSERV.UA.EDU> On Behalf Of
>> FRISBIE, JIM
>> Sent: Tuesday, February 19, 2019 9:21 AM
>> To: IBM-MAIN@LISTSERV.UA.EDU
>> Subject: TSO CLIST Query
>> 
>> I'm trying to write a CLIST to make life easier on our Operations staff. They
>> constantly have problems correctly entering the dataset name of the offload
>> tape, so I created this simple CLIST to help.
>> 
>> 
>> 
>> PROC 1 OFILE
>> 
>> CONTROL MSG LIST CONLIST
>> 
>> WRITE DSN=&OFILE
>> 
>> $TOFFLOAD1,DSN=&OFILE
>> 
>> 
>> 
>> From ISPF, the operator issues =3.4 to list the available offload tapes.
>> 
>> 
>> 
>> DSLIST - Data Sets Matching TS.PSYS.OFF*
>> 
>> Command ===>
>> 
>> 
>> 
>> Command - Enter "/" to select action
>> 
>> -----------------------------------------
>> 
>>         TS.PSYS.OFF1.FEB01
>> 
>>         TS.PSYS.OFF1.FEB04
>> 
>>         TS.PSYS.OFF1.FEB05
>> 
>> offdsn   TS.PSYS.OFF1.FEB06
>> 
>>         TS.PSYS.OFF1.FEB07
>> 
>>         TS.PSYS.OFF1.FEB08
>> 
>>         TS.PSYS.OFF1.FEB11
>> 
>>         TS.PSYS.OFF1.FEB12
>> 
>>         TS.PSYS.OFF1.FEB13
>> 
>>         TS.PSYS.OFF1.FEB14
>> 
>> 
>> 
>> My plan was that the operator would select the correct tape and enter the
>> CLIST name in the command line. The CLIST would do the rest.
>> 
>> 
>> 
>> The CLIST returns the selected data set name but it's enclosed in single
>> quotes. I'm including the message it returns:
>> 
>> 
>> 
>> WRITE DSN='TS.PSYS.OFF1.FEB06'
>> 
>> DSN='TS.PSYS.OFF1.FEB06'
>> 
>> $TOFFLOAD1,DSN=&OFILE
>> 
>> $TOFFLOAD1,DSN='TS.PSYS.OFF1.FEB06'
>> 
>> A command entered or contained in a CLIST has invalid syntax.
>> 
>> 
>> 
>> How do I turn off those quotes?
>> 
>> 
>> Jim Frisbie
>> Mainframe Engineering
>> Sr Systems Programmer
>> 919-831-4711
>> 
>> This email may contain confidential and privileged material for the sole use
>> of the intended recipient. If you are not the intended recipient, please
>> contact the sender and delete all copies. Any review or distribution by
>> others is strictly prohibited. Personal emails are restricted by policy of
>> the State Employees' Credit Union (SECU).  Therefore SECU specifically
>> disclaims any responsibility or liability for any personal information or
>> opinions of the author expressed in this email.
>> 
>> ----------------------------------------------------------------------
>> For IBM-MAIN subscribe / signoff / archive access instructions, send email to
>> lists...@listserv.ua.edu with the message: INFO IBM-MAIN
> 
> ----------------------------------------------------------------------
> For IBM-MAIN subscribe / signoff / archive access instructions,
> send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN

----------------------------------------------------------------------
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