Forum Discussion
Filter with calculated measures
- 9 years ago
how can i filter with dynamically filter?
Have you tried the VAR function that I mentioned in your previous thread? In this scenario, the formula should like below.
=
VAR m = Measures
RETURN
CALCULATE ( SUM ( 'x' ), FILTER ( 'y', column = m ) )If the result is still not right, could you post your table structure and the measures you use, and some sample data in your case?:smileyhappy:
Regards
how can i filter with dynamically filter?
Have you tried the VAR function that I mentioned in your previous thread? In this scenario, the formula should like below.
=
VAR m = Measures
RETURN
CALCULATE ( SUM ( 'x' ), FILTER ( 'y', column = m ) )
If the result is still not right, could you post your table structure and the measures you use, and some sample data in your case?:smileyhappy:
Regards
- Anonymous5 years agoNot applicable
Can somone tell me why this works
=
VAR m = Measures
RETURN
CALCULATE ( SUM ( 'x' ), FILTER ( 'y', column = m ) )and this does not:
CALCULATE ( SUM ( table1[x] ), FILTER ( table1, table1[y] = measure ) )
I had a sample excel where it worked fine in but i had to implement your VAR method for my SSAS and powerpivot model....
- MP_1239 years agoMicrosoft Employee
v-ljerr-msftthanks! your awsome!
- amalhotr8 years agoNew Member
VAR m = [Measure]
RETURN
CALCULATETABLE('Table 2','Table 2'[QUARTER]=m) Not working with calculatedtable DAX function- Michiel8 years agoResolver III
What is the error that you get? You cannot use this directly in a measure, but that is because a measure must return a scalar value, not a table (which is wat CALCULATEDTABLE returns). So at least it should be wrapped in a table aggregation function.
- DesireeMaya228 years agoNew Member
Hi
I tried the same thing with a filtren that you can choise in the report (a visual filter)
Viajes de Cir - Dest 2 = IF([Base Ajustada Origen]= "HID",CALCULATE(COUNTROWS(Circuitos),'Circuitos'[MAPA DESTINO]="HID"),4)
Measure = Base Ajustada Origen, the value that it generate is HID
But it not recognize the mearsure like a text. The messeage said that i can“t used a mesure with a dinamic visual.
could you help me?
- MS_12344 years agoNew Member
Hi,
I have a table with 3 Columns
Report Name | Manager | Status
Status contains Values: Pass, Fail, NAI want to calculate % Pass for each manager. NA should be calculated in %of calculation.
I created one measure to calculate Total of Pass and Fail. and tried creating another measure for only "Pass". But its same % value for each manager.I am showing this data in Matrix. Please guide. Thanks!
- khalidwaleed4 years agoFrequent Visitor
Hi v-ljerr-msft , I was also stuck with this problem for more than 2 days till I came across this answer. Can you please briefly tell why it works. I am totally clueless.