Hi,
I have a rule in SAS VA , that reads data for the current month we are in. what i want to do is create a rule where i don't have to update the 202311 to 202312, the rule should automatically update to the current month we are in and update the figures. the rule that i am currently using is as follow, but you will notice that month book is 202311- so that means i would have to manually update next month to 202312, what parameters would i use instead of 202311?
IF ( 'Month Booked (yyyy/mm)'n In (202311) )
RETURN 1
ELSE 0
Try:
format(datepart(now()), yym6.)='202312'
Look for the format value that returns yyyymm
Hi,
Try this:
(year(date)<=year(datepart(now()))
if you want to filter for previous years and filter the current year until the current month, you can use:
(year(date) < year(datepart(now())))
or
(Year(date)=year(datepart(now())) and month(date)<=month(datepart(now())))
Join us for SAS Innovate 2025, our biggest and most exciting global event of the year, in Orlando, FL, from May 6-9.
Early bird rate extended! Save $200 when you sign up by March 31.
See how to use one filter for multiple data sources by mapping your data from SAS’ Alexandria McCall.
Find more tutorials on the SAS Users YouTube channel.