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

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.

Reply
bertc
New Member

add calculated rows to PowerBI Matrix

Hi I have created a matrix visual which is built using this dax

 

Category = 
SWITCH(
    TRUE(),
    Diario[Código cuenta] >= 7000000000 && Diario[Código cuenta] <= 7130000000 || Diario[Código cuenta] = 6290000009, "Ventas De Mercaderias",
    Diario[Código cuenta] >= 7300000000 && Diario[Código cuenta] <= 7330000000, "TRABAJOS REALIZADOS OTRAS EMPRESAS",
    Diario[Código cuenta] >= 7400000000 && Diario[Código cuenta] <= 7470000000, "Subvenciones",
    Diario[Código cuenta] >= 6400000000 && Diario[Código cuenta] <= 6490000007 , "COSTE PERSONAL",
    Diario[Código cuenta] >= 6210000002 && Diario[Código cuenta] <= 6210000012, "Canon/Royalty ",
    Diario[Código cuenta] >= 6210000000 && Diario[Código cuenta] <= 6310000060, "COSTES FUNCIONAMIENTO",
    Diario[Código cuenta] >= 6700000000 && Diario[Código cuenta] <= 6990000000, "AMORTIZACIONES & DEPRECIACIONES",
    Diario[Código cuenta] >= 6600000000 && Diario[Código cuenta] <= 7690000002,"RESULTADO FINANCIERO /DIF. CAIXES",
    Diario[Código cuenta] >= 6301000000 && Diario[Código cuenta] <= 6301000000,"IMPUESTO DE SOCIEDADES",
    Diario[Código cuenta] >= 6000000000 && Diario[Código cuenta] <= 6080000003, "COSTE DE MERCADERIAS",
    Diario[Código cuenta] = 6240000000, "Transportes",
    Diario[Código cuenta] = 6080000003, "ABONO SALDO",
    "Other"
)

 

 

And the visual is 

bertc_1-1712516060177.png


I would like to add a row to this matrix say EBITDA which is calculated by subtracting one subtotal from another from this matrix ( for eg : Ventas De Mercaderias - Coste Personal.

How can I do this?

Sample date is 

bertc_2-1712516326392.png

bertc_3-1712516363885.png

 


Please help

1 ACCEPTED SOLUTION
Anonymous
Not applicable

Hi @bertc ,

Please have a try.

You can create a measure.

EBITDA = 
SUMX(
    FILTER(
        'Diario',
        'Diario'[Category] = "Ventas De Mercaderias"
    ),
    'Diario'[Value]
)
-
SUMX(
    FILTER(
        'Diario',
        'Diario'[Category] = "Coste Personal"
    ),
    'Diario'[Value]
)

 

How to Get Your Question Answered Quickly - Microsoft Fabric Community

 

If it does not help, please provide more details with your desired output and pbix file without privacy information (or some sample data) .

 

Best Regards
Community Support Team _ Rongtie

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

 

 

 

 

View solution in original post

1 REPLY 1
Anonymous
Not applicable

Hi @bertc ,

Please have a try.

You can create a measure.

EBITDA = 
SUMX(
    FILTER(
        'Diario',
        'Diario'[Category] = "Ventas De Mercaderias"
    ),
    'Diario'[Value]
)
-
SUMX(
    FILTER(
        'Diario',
        'Diario'[Category] = "Coste Personal"
    ),
    'Diario'[Value]
)

 

How to Get Your Question Answered Quickly - Microsoft Fabric Community

 

If it does not help, please provide more details with your desired output and pbix file without privacy information (or some sample data) .

 

Best Regards
Community Support Team _ Rongtie

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

 

 

 

 

Helpful resources

Announcements
October Power BI Update Carousel

Power BI Monthly Update - October 2025

Check out the October 2025 Power BI update to learn about new features.

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.

Top Kudoed Authors