sas - %bquote doesn't mask unpaired bracket -


according %bquote() macro function documentation don't have mark unpaired "(" % assign macro variable.

but code doesn't work reason (variable var blank result):

%let var=%bquote((); %put &var; 

why? how can fix code produce expected result?

you're confusing masking @ execution time masking @ compile time.

%bquote masks special characters at execution time:

the %bquote function treats parentheses , quotation marks produced resolving macro variable references or macro calls special characters masked @ execution time. (it not mask parentheses or quotation marks in argument @ compile time.)

to mask @ compile time, must since assigning value in %let, must use %str, does require parenthesis preceded %.

%let var=%str(%();  %put &var; 

Comments

Popular posts from this blog

php - Vagrant up error - Uncaught Reflection Exception: Class DOMDocument does not exist -

vue.js - Create hooks for automated testing -

Add new key value to json node in java -