I'm quite new to SAS and need your help regarding creating date macro variable.
I have 6 tables at the moment and all of them are refreshed on daily basis. Each month i'm trying to get the data with the last date stamp
%let last_month = %sysfunc(intnx(month,%sysfunc(today()),-1,e), yymmn6.);
and this only gives me the last date of previous month. This doesn't work for me as sometimes the last date of the record doesn't exist (for example if last record date of APril was 28th as 29,30 was a weekend).