Search notes:

SAS programming, function putn

putn allows to convert a numeric value to a character value with a dynamic format. In contrast, the format of the put statement must be specified at compile time.
data _null_;

   num_days_since_jan_1st_1960 = 15;

/* Convert the numeric value num_days_since_jan_1st_1960
   to a character with width=11.
   Since num_days_since_jan_1st_1960 is a numeric, we
   use putn (rather than putc) */
   format_ = 'date';
   width   = 11;
   
   dt = putn(num_days_since_jan_1st_1960, format_, width);
   put dt=;

   dt_type = vtype(dt);
   put dt_type=;

run;
Github repository about-SAS, path: /programming/functions/putn.sas

See also

%sysfunc(putn…))
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...', 1759338228, '216.73.216.88', 'Mozilla/5.0 App...', NULL) #2 /home/httpd/vhosts/renenyffenegger.ch/httpsdocs/notes/Companies-Products/SAS/programming/functions/putn(61): insert_webrequest() #3 {main} thrown in /home/httpd/vhosts/renenyffenegger.ch/php/web-request-database.php on line 78