Places quotes around a string and places it into a variable.
&ZQUOTE text ... text &ZQUOTE2 text ... text
&ZQUOTE provides a means of quoting a string using single or double quotes. &ZQUOTE2 also quotes data, but uses only single quotes. For the rules used, see Notes.
&ZQUOTE and &ZQUOTE2 are built-in functions and must be used to the right of an assignment statement.
Operands:
The text to be quoted
Return Codes:
&ZFDBK is set to indicate the success or failure of the quoting procedure:
Quote successful
The data cannot be quoted. This occurs if the string for quoting is too long to fit within an NCL variable. The input is assigned to the output variable without change.
Examples:
&A=&ZQUOTE ABC DEF -* results in &A set to “ABC DEF” &B=&ZQUOTE say “Hello” -* &B is set to 'say “Hello”' &C=&ZQUOTE say “G'day” -* &C is set to 'say “G''day”' &D=&ZQUOTE2 say “G'day” -* &D is set to 'say “G”day”'
Notes:
&ZQUOTE and &ZQUOTE2 is used to quote a string which is later analyzed by &SETVARS.
&ZQUOTE quotes the text according to the following rules:
&ZQUOTE2 uses the following rules:
| Copyright © 2009 CA. All rights reserved. |
|