Date: Thu, 5 Feb 2009 12:35:35 -0600
Reply-To: "./ ADD NAME=Data _null_;" <iebupdte@GMAIL.COM>
Sender: "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From: "./ ADD NAME=Data _null_;" <iebupdte@GMAIL.COM>
Subject: Re: How do I programatically check for macro-quoting?
In-Reply-To: <D1C0E8758EDA0B4787F028FB3A7DB50801914EC59E@EX-CMS01.westat.com>
Content-Type: text/plain; charset=ISO-8859-1
Maybe another possibility is to look for delta characters in the
values by viewing through SASHELP.VMACRO or DICTIONARY.MACROS .
214 %let amIQuoted = Don%str(%')t Know;
215 %put NOTE: AMIQUOTED=&amIQuoted;
NOTE: AMIQUOTED=Don't Know
216
217 data _null_;
218 set sashelp.vmacro(where=(scope='GLOBAL'));
219 put name= value=hex32.;
220 *Write code to look for delta characters;
221 *I don't know all the delta characte values;
222 run;
name=AMIQUOTED value=446F6E01110274204B6E6F7720202020
'01 11 02'x looks like (quote ' endquote)
But do you need to know? Could you just SUPERQ everything an not worry
about it?
On 2/5/09, Mike Rhoads <RHOADSM1@westat.com> wrote:
> Roland,
>
> Off the top of my head, I would write a second macro to call the macro being tested.
>
> Write the calling macro to pass arguments in such a way that the result being returned is one where macro quoting would make a difference (e.g., CA OR WA IN), and then have it use the returned value in a way that would break the subsequent macro code if the result was not quoted (after a %IF, perhaps).
>
> HTH!
>
> Mike Rhoads
> RhoadsM1@Westat.com
>
>
> -----Original Message-----
> From: SAS(r) Discussion [mailto:SAS-L@LISTSERV.UGA.EDU] On Behalf Of RolandRB
> Sent: Thursday, February 05, 2009 11:52 AM
> To: SAS-L@LISTSERV.UGA.EDU
> Subject: How do I programatically check for macro-quoting?
>
>
> If it is a requirement of a macro to return a result macro-quoted, and I am testing this macro, then how do I programatically check for macro- quoting?
>
|