Pivot Rows and calculations

This post says the solution is to use the “in” function. I tried it and it seems to work:

First you have to use parameters for your Country and Year filters. Then rewrite the calculated fields as follows:

Month Total =
sumOver(ifelse(in(Year, ${Year}) AND in(Country, ${Country}), Value, 0), [Month], PRE_FILTER)

Oct Total =
sumOver(ifelse(Month = “Oct” AND in(Year, ${Year}) AND in(Country, ${Country}), Value, 0), , PRE_FILTER)

2 Likes