Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello, I have some dimensions : Product1, Product2, Product3, ...I'm using those dimensions in set analysis I have a filter to select the numero of the product (1, 2, 3 ...) Is it possible to set a variable to determine the dimension ? Equivalent to : if(getfieldselection(value) = 1, sum({} measure), if(getfieldselection(value) = 2, sum({} measure), if(getfieldselection(value) = 3, sum({} measure), )))) I would like something like : myvariable = 'Product'&getfieldselection(value) to do sum({} measure),
Hi RileyDylan ,
Your approach above seems to be correct 🙂
i would do like this:
Backend:
Create a inline table:
Load * Inline [
Value
1
2
3
];
Use "value" as a drop down filter and set as only one value selected.
Create 2 variable:
vDimension = 'Product'&Getfieldselections(value) //Assuming your all dimensions start with "Product" prefix
vMeasure = Sum({<$(vDimension)={'any value'}>}Measure) //use variable vMeasure in your charts