Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
I try to create a measure with dynamic set analysis!
I have a few charts with the same measure, the measure preset top X materials based on the total consumption or present all the materials (based on selection - the customer can choose to see top X materials or all materials) .
So in order to create dinamic mesure , I created the below measure :
Sum({$< [Material Name] = {$(=vAstrix)}>} [Actual Overall Usage])
In addtion, I created the variable vAstrix to change the set analysis value based on selection (All or top X):
if($(vTopN) = 0,"*","$(=Rank(sum({$<Technology={'$(=pick(WildMatch(GetPossibleCount(Technology),0,1,'*'),'FDM',Technology,'FDM'))'} >} [Actual Overall Usage]))) < $(=vTopN)")
vTopN - hold the number for the top materials ( for example, if the user wants to see top 5 materials this variable will be 5)
So the vAstrix will change the based on user selection, in case the user selected "All" the vAstrix is * otherwise the astrix will be the formula :
"$(=Rank(sum({$<Technology={'$(=pick(WildMatch(GetPossibleCount(Technology),0,1,'*'),'FDM',Technology,'FDM'))'} >} [Actual Overall Usage]))) < $(=vTopN)"
for some reason, it doesn`t work, any suggestion?
thanks
hi
try this
if($(vTopN) = 0,"*","=Rank(sum({$<Technology={'$(=pick(WildMatch(GetPossibleCount(Technology),0,1,'*'),'FDM',Technology,'FDM'))'} >} [Actual Overall Usage])) < $(=vTopN)")
I changed the variable vAstrix to your formula and it still not working .