Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

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.

Reply
calliandutra
Frequent Visitor

Calculate row in matrix

Hi,

 

I've a matrix table and i need put a row calculated between rows.

 

The Descriptions is in a table dimension, as below:

 

1 - Sales

2 - Spending

3 - Result

4 - Other Spending

6 - Imobbilized

7 - New Result

 

PowerBI.png

 

The records in my fact table are relationed with the codes 1, 2, 4 and 6. The row 3 and 7 i need calculate.

 

Look the picture attachment

1 REPLY 1
v-huizhn-msft
Employee
Employee

Hi @calliandutra,

You can try to create the two measure using the following formula. 

3calculate-Row=CALCULATE(SUM(Table[sale]),FILTER(Table,Table[DescricaoN1]="1-ReCEITAS OPERACIONAIS"))-CALCULATE(SUM(Table[sale]),FILTER(Table,Table[DescricaoN1]="2-GASTOS OPERACIONAIS TOTAL"))

7calculate-Row=CALCULATE(SUM(Table[sale]),FILTER(Table,Table[DescricaoN1]="4-GASTOS NAO OPERACIONIS"))-CALCULATE(SUM(Table[sale]),FILTER(Table,Table[DescricaoN1]="6-Capital Social"))


Then add the measure as value level and check if it works fine.

If you have other issues, please feel free to ask.

Best Regards,
Angelia

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.

Top Solution Authors