Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!To celebrate FabCon Vienna, we are offering 50% off select exams. Ends October 3rd. Request your discount now.
Hey,
I have a column of data and beside it a dax measure:
Item 1 | 60
Item 2 | 30
Item 3 | 30
I need to create a third measurement, which is the first dax measure divided by the sum of all the dax measures in that second column. For ex, the third measure for item 1 would be 60/(60+30+30)
Item 1 | 60 | 60/(60+30+30)
Item 2 | 30 | 30/(60+30+30)
Item 3 | 30 | 30/(60+30+30)
How can I obtain the sum of the first dax measure so that I can divide the first dax measure by the total sum of the first dax measure? Research has led me to a lot of similar questions but no great answers yet. SumX, All, Allselected don't appear to obtain this number.
Thanks!
I'm trying to do the same thing, but the DAX measure isn't part of a table as a calculated column, it's just a standalone Measure (or variable) named "distance". I need to create a seperate variable wivch would be like the example above. In this case it would be similar to Measure =distance/SUMX(distance).
@Anonymous,
Try something like:
Measure = VAR totalSum = CALCULATE(SUM(YourTableName[Value]),ALL(YourTableName)) VAR valueTotal = SUM(YourTableName[Value]) RETURN DIVIDE(valueTotal,totalSum,0)
Proud to be a Super User!
Thanks for the reply Chris,
I actually needed all filters to remain present except the context filter. I realized this could be accomplished by using AllSelected and specifying the columns causing row splits in your table, in this case the column for item1, item2, and item3.
MeasureTitle = CALCULATE(SUM(table[column]), ALLSELECTED(table[column]))
It seems like part of the key would be to ignore the row context.
User | Count |
---|---|
98 | |
76 | |
75 | |
48 | |
26 |