Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello all,
My KPI dashboard has around 10 measures most of them are calculated Master item measures. Example metrics: Gross Sales, Net Sales, TSales, FSales, PartSales etc.
I have dimensions like date, AreaManager, SalesManager and Salesperson
I need a dropdown/option to choose which metric user wants to view for the hierarchies and see their ranking based on the metric selected.
Can you please let me know how I can achieve this? Your inputs will be appreciated.
Hi @Aag, you can use the variable object of the dashboard bundle to create the different options and associate each to a number value.
And use this value to select wich measure to show, this can be done in different ways: you can have a table and use "show if" condition to show/hide expressions.
Or if it's in a KPI or similiar you can use Pick() function to select the expression, but you have to copy the expression, in this case you can't use the master measures, it will be something like:
Pick($(varMeasure), [ExpressionFor1], Expressionfor2+...)
varMeasure is the variable used to configure the variable object
There can be multiple ways of achieving this.. below is one example.. using Island Table and Variable
1. Create measure Island Table for Filter
Measures:
Load * inline [
Measure
Gross Sales
Net Sales
TSales
FSales
FSales
PartSales
];
2. Create vMeasure variable to track what is currently selected
vMeasure : if( GetSelectedCount(Measure)=1 , Measure , 'Net Sales')
// Here 'Net Sales' is default value if nothing or more than one item is selected
// Note : You can Avoid this step completely by marking Measure field as 'Always one selected'
3. Use vMeasure in calculation
if($(vMeasure) = 'Net Sales', Sum(data))
// You can also use INT ids in Island table to avoid String comparison.
// if you have gone with single field select; directly use Measure field in comparison condition
I hope this answers your question. 😄
Hi @Aag, you can use the variable object of the dashboard bundle to create the different options and associate each to a number value.
And use this value to select wich measure to show, this can be done in different ways: you can have a table and use "show if" condition to show/hide expressions.
Or if it's in a KPI or similiar you can use Pick() function to select the expression, but you have to copy the expression, in this case you can't use the master measures, it will be something like:
Pick($(varMeasure), [ExpressionFor1], Expressionfor2+...)
varMeasure is the variable used to configure the variable object
There can be multiple ways of achieving this.. below is one example.. using Island Table and Variable
Measure
Gross Sales
Net Sales
TSales
FSales
FSales
PartSales
... So on
vMeasure : if( GetSelectedCount(Measure)=1 , Measure , 'Net Sales')
// Here 'Net Sales' is default value if nothing or more than one item is selected
// Note : You can Avoid this step completely by marking Measure field as 'Always one selected'
if($(vMeasure) = 'Net Sales', Sum(data))
// You can also use INT ids in Island table to avoid String comparison.
// if you have gone with single field select; directly use Measure field in comparison condition
I hope this answers your question.
There can be multiple ways of achieving this.. below is one example.. using Island Table and Variable
Create measure Island Table for Filter
Measure
Gross Sales
Net Sales
TSales
FSales
FSales
PartSales
Create vMeasure variable to track what is currently selected
vMeasure : if( GetSelectedCount(Measure)=1 , Measure , 'Net Sales')
// Here 'Net Sales' is default value if nothing or more than one item is selected
// Note : You can Avoid this step completely by marking Measure field as 'Always one selected'
Use vMeasure in calculation
if($(vMeasure) = 'Net Sales', Sum(data))
// You can also use INT ids in Island table to avoid String comparison.
// if you have gone with single field select; directly use Measure field in comparison condition
I hope this answers your question.