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())))
April 27 – 30 | Gaylord Texan | Grapevine, Texas
Walk in ready to learn. Walk out ready to deliver. This is the data and AI conference you can't afford to miss.
Register now and lock in 2025 pricing—just $495!
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.