Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.
I have a matrix with column C , rows(column R with values R1,R2,R3 and R4) and amount measure. My matrix looks like below. Column C4 is the calculation I am trying to achieve. C4 = C3- (C1 + C2). C1,C2,C3,C4 are all labels and values of column C. I want to calculate amount measure for C4 such that it fetches corresponding amount for C1,C2 and C3 and perform the required calculation.
C1 | C2 | C3 | C4 | |
R1 | 100 | 200 | 500 | 200 |
R2 | 200 | 300 | 600 | 100 |
R3 | 300 | 400 | 800 | 100 |
R4 | 400 | 500 | 1000 | 100 |
Solved! Go to Solution.
Hi @Anonymous ,
Create a measure as below:
C4 =
VAR _sum=CALCULATE(SUM('Table'[Value]),FILTER('Table','Table'[C]="C1"))+CALCULATE(SUM('Table'[Value]),FILTER('Table','Table'[C]="C2"))
var _sum2=CALCULATE(SUM('Table'[Value]),FILTER('Table','Table'[C]="C3"))
Return
IF(ISINSCOPE('Table'[C]),SUM('Table'[Value]),_sum2-_sum)
And you will see:
For the related .pbix file,pls see attached.
Best Regards,
Kelly
Did I answer your question? Mark my post as a solution!
Hi @Anonymous ,
Create a measure as below:
C4 =
VAR _sum=CALCULATE(SUM('Table'[Value]),FILTER('Table','Table'[C]="C1"))+CALCULATE(SUM('Table'[Value]),FILTER('Table','Table'[C]="C2"))
var _sum2=CALCULATE(SUM('Table'[Value]),FILTER('Table','Table'[C]="C3"))
Return
IF(ISINSCOPE('Table'[C]),SUM('Table'[Value]),_sum2-_sum)
And you will see:
For the related .pbix file,pls see attached.
Best Regards,
Kelly
Did I answer your question? Mark my post as a solution!
@Anonymous , I think you need a hybrid display. That is not available out of the box.
You can refer Blog from Paul and Greg, if those can help
Also, vote for this idea
Hybrid Table
https://ideas.powerbi.com/ideas/idea/?ideaid=9bc32b23-1eb1-4e74-8b34-349887b37ebc
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
109 | |
99 | |
77 | |
66 | |
54 |
User | Count |
---|---|
144 | |
104 | |
102 | |
87 | |
64 |