Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi everyone,
im starting to taking confidence with set expression.
My goal is to visualize YoY sum(sales) from a year who i can get from Order Date.autoCalendar.Year.
this is my set expression
sum({<[Order Date.autoCalendar.Year] = {[Order Date.autoCalendar.Year]}-1>}Sales)
Can you help me to figure out why?
Actually, you have an even simpler solution:
sum({<[Order Date.autoCalendar.YearsAgo] = {1}>}Sales)
if you want a dynamic expression you can use this:
sum({<[Order Date.autoCalendar.YearsAgo] = {"$(=min([Order Date.autoCalendar.YearsAgo])+1)"}>}Sales)
it doesn't work...
i managed a solution like this one
Sum({<[Order Date.autoCalendar.Year] = {$(=year([Order Date.autoCalendar.Year])-1)}>} Sales)
Sum({<[Order Date.autoCalendar.Year] = {"$(=Max([Order Date.autoCalendar.Year],2))"}>} Sales)
OR
Sum({<[Order Date.autoCalendar.Year] = {"$(=Max([Order Date.autoCalendar.Year])-1)"}>} Sales)