Hi all,
Is there any other way to create MACRO VARIABLES except %let and callsymput.This is an interview question.
Thanks&Regards
Rawindarreddy
you can create using proc sql and also when you create a macro program parameters are automatically macro variables.
Hi,
%local %global :into(proc sql);
Thanks,
Shiva
Hi...
we can create macro variables in many ways.
and if you use %do statements in with in the macro,
for example %macro test;
%do i=1 %to 10;
..........
...........
%end;
in that example "i" also become a local macro variable.
and I don't think that we can create macro variables directly by using %local and %global statements.
generally we use % local and %global statement before %let statement to specify weather the macro variable become local or global.
Thanks
Sanjeev K
That's not entirely correct. %local and %global create macro variables with null values. Even without assigning a value to them with %let, you can reference them without error.
Join us for SAS Innovate April 16-19 at the Aria in Las Vegas. Bring the team and save big with our group pricing for a limited time only.
Pre-conference courses and tutorials are filling up fast and are always a sellout. Register today to reserve your seat.
Learn how use the CAT functions in SAS to join values from multiple variables into a single value.
Find more tutorials on the SAS Users YouTube channel.