I can't understand why the filter references 'Rolling Stocktake Schedule'n in both the IF and RETURN statements for all three values of 'Rolling Stocktake Schedule'n, or why the OR statement is used.
Is the filter stating: If 'Rolling Stocktake Schedule' is equal to "Year One" then return any rows where 'Rolling Stocktake Schedule' is equal to "Year One" or 'Controlled Item Indicator'n = 'YES', excluding all others, then repeating this for "Year Two" and "Year Three".
In other words, return all rows where 'Rolling Stocktake Schedule' is equal to "Year One", "Year Two", "Year Three", or 'Controlled Item Indicator'n = 'YES'. Is this right?
Also, does the final ELSE statement return any rows where 'Main Asset Number'n = Missing, or excludes these?
Hi @JeremyAT, in your post I see different variables in the IF and in the OR clause:
In the IF it's 'Rolling Stocktake Schedule'n and in the OR it's 'Rolling Stocktake Timetable'n.
Maybe you should look into the difference of the two variables?
Please keep the community friendly. Like posts you agree with or like. Mark helpful answers as “accepted solutions”. Generally have a look at https://communities.sas.com/t5/Getting-Started/tkb-p/community_articles
Hi Markus, I managed to understand how the filter was working by creating a calculated item with the same code and looking at what was being included and excluded. In the end, I managed to work out that the filter could be simplified to the follow.
Registration is open! SAS is returning to Vegas for an AI and analytics experience like no other! Whether you're an executive, manager, end user or SAS partner, SAS Innovate is designed for everyone on your team. Register for just $495 by 12/31/2023.
If you are interested in speaking, there is still time to submit a session idea. More details are posted on the website.