From 4b375e0b8ca63d123282b2e37a6138d515e8c771 Mon Sep 17 00:00:00 2001 From: Allan Bowe Date: Fri, 19 Mar 2021 20:34:16 +0100 Subject: [PATCH] fix: leading zero in time component of mf_uid() --- all.sas | 6 +++--- base/mf_uid.sas | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/all.sas b/all.sas index 7194df4..629b233 100644 --- a/all.sas +++ b/all.sas @@ -1426,12 +1426,12 @@ Usage: %mend;/** @file - @brief Creates a Unique ID based on system time in a friendly format + @brief Creates a unique ID based on system time in friendly format @details format = YYYYMMDD_HHMMSSmmm__<3randomDigits> %put %mf_uid(); - @version 9.2 + @version 9.3 @author Allan Bowe **/ @@ -1440,7 +1440,7 @@ Usage: )/*/STORE SOURCE*/; %local today now; %let today=%sysfunc(today(),yymmddn8.); - %let now=%sysfunc(compress(%sysfunc(time(),time12.3),:.)); + %let now=%sysfunc(compress(%sysfunc(time(),tod12.3),:.)); &today._&now._&sysjobid._%sysevalf(%sysfunc(ranuni(0))*999,CEIL) diff --git a/base/mf_uid.sas b/base/mf_uid.sas index 53391f4..01eee7f 100644 --- a/base/mf_uid.sas +++ b/base/mf_uid.sas @@ -1,11 +1,11 @@ /** @file - @brief Creates a Unique ID based on system time in a friendly format + @brief Creates a unique ID based on system time in friendly format @details format = YYYYMMDD_HHMMSSmmm__<3randomDigits> %put %mf_uid(); - @version 9.2 + @version 9.3 @author Allan Bowe **/ @@ -14,7 +14,7 @@ )/*/STORE SOURCE*/; %local today now; %let today=%sysfunc(today(),yymmddn8.); - %let now=%sysfunc(compress(%sysfunc(time(),time12.3),:.)); + %let now=%sysfunc(compress(%sysfunc(time(),tod12.3),:.)); &today._&now._&sysjobid._%sysevalf(%sysfunc(ranuni(0))*999,CEIL)