Search notes:

SAS programming: function symget

symget gets the value of a macro variable at code execution time.
/*
   symput assigns a value to a macro variable.

   Note: the assigned value cannot be used in the same data step, because
   the macroprosses must be invoked again to resolve it.
*/

%let tq84_macro_var = hello world;

data _null_;
  call symput("tq84_macro_var", """good bye""");
  put &tq84_macro_var;
  /* Prints: hello world */
run;

data _null_;
  put &tq84_macro_var;
  /* Prints: good bye */
run;
Github repository about-SAS, path: /programming/call-routines/symput.sas

See also

SAS: Interaction between macros and data steps with execute, symget and symput
symput
functions

Index

Fatal error: Uncaught PDOException: SQLSTATE[HY000]: General error: 8 attempt to write a readonly database in /home/httpd/vhosts/renenyffenegger.ch/php/web-request-database.php:78 Stack trace: #0 /home/httpd/vhosts/renenyffenegger.ch/php/web-request-database.php(78): PDOStatement->execute(Array) #1 /home/httpd/vhosts/renenyffenegger.ch/php/web-request-database.php(30): insert_webrequest_('/notes/Companie...', 1745610163, '3.133.144.147', 'Mozilla/5.0 App...', NULL) #2 /home/httpd/vhosts/renenyffenegger.ch/httpsdocs/notes/Companies-Products/SAS/programming/functions/symget(65): insert_webrequest() #3 {main} thrown in /home/httpd/vhosts/renenyffenegger.ch/php/web-request-database.php on line 78