Starting December 3, join live sessions with database experts and the Microsoft product team to learn just how easy it is to get started
Learn moreGet certified in Microsoft Fabric—for free! For a limited time, get a free DP-600 exam voucher to use by the end of 2024. Register now
Hello Community,
I understand that VALUES() returns a distinct one column table.
I also understand that using VALUES() with one filter context and then using that as a filter for a calculation with another filter context will run the calculation only taking the distinct values generated from the first context into account. Hope I'm not far off.
But, I've come across this behaviour which I don't really understand and am hoping someone can explain.
If I do a simple SalesAmt = SUM('FactTable'[SalesAmt]) I obviously just get a simple sum, but if I the do this:
CALCULATE( [SalesAmt], VALUES('FactTable'[CustomerID])) then I get a very different result which I cannot explain to myself
What am I filtering away and why?
That is odd. Please share more info about both your model (tables and relationships) and the visual (which fields and measures used in it).
Pat
I made a mistake - the measure I am using is not a simple sum but a SUMX()
SUMX( 'FactTable', 'FactTable'[SalesAmt]) * 'FactTable'[Factor] )
I would still like an explanation but I apologize for the confusion
Hi @BIanon ,
Here I create a sample and I couldn't reproduce your issue. Please share a sample file with me and show me a screenshot with the result you want. This will make it easier for me to find the solution.
Best Regards,
Rico Zhou
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Starting December 3, join live sessions with database experts and the Fabric product team to learn just how easy it is to get started.
March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Early Bird pricing ends December 9th.
User | Count |
---|---|
88 | |
86 | |
82 | |
66 | |
49 |
User | Count |
---|---|
138 | |
110 | |
104 | |
66 | |
64 |