Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello all,
I need some help on indirect set analysis. I am currently using v9
[ code ]sum(({<Year={$(=max(Year))>}, Customer=p({<Year={$(=max(Year)-1)}>}) Sales)[ /code ]
it should return this year's sales for customers who had sales last year, but I am having syntax error which that I can not find.
Thanks,
Ryan
Hi Ryan,
Here is the code, I haven't actually checked the results but the syntax is correct and presents some figures to check.
As a tip I would always try and get syntax correct using a pivot table and create a second expression with a '1' in the expression.
This means that there is some data always in the pivot table. This allows you to hover over with the mouse, the expression you are trying to get right, a popup is then presented showing the evaluated $ expansion parts of your expression which you may have wrong.
sum({$<Year={$(=max(Year))}, Customer=p({<Year={$(=max(Year)-1)}>})>} Sales)
Hope this is of help,
Neil
what does the P in the formula?
p({<Year={$(=max(Year)-1)}>})>}
P is for Possible you can also use E for excluded
Works for me