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

Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes! Register now.

Reply
gra_197
Helper I
Helper I

Usung a measure

Hi I am trying to create a measure on the following 

1000054594.jpg

 I want a multi row card to pull the following 

Calculate the number of rows where the type is "Underactive", where the dept is "claims",the reason is "write off" and sum the total amount.

 

Thank you

2 ACCEPTED SOLUTIONS
FBergamaschi
Solution Sage
Solution Sage

CALCULATE ( 
            SUM ( Table[cost]),

             Table[Type] = "Underactive",
             Table[dept]= "Claim",
             Table[reason] = "Write off"
)

 

If this helped, please consider giving kudos and mark as a solution

@me in replies or I'll lose your thread

consider voting this Power BI idea

Francesco Bergamaschi

MBA, M.Eng, M.Econ, Professor of BI

View solution in original post

Hi @gra_197 ,

Thanks for reaching out to the Microsoft fabric community forum.

 

I’ve revalidated your updated requirement, and you’re absolutely right  the original measure shared above works perfectly to calculate the sum of cost where Type = "Underactive", dept = "Claim" and reason = "Write off". To also include the count of rows matching the same filters, I created a second measure using COUNTROWS inside the same filter logic.

 

Here’s the additiona measure:

Row Count Measure =
CALCULATE (
COUNTROWS ( 'DataTable' ),
'DataTable'[Type] = "Underactive",
'DataTable'[dept] = "Claim",
'DataTable'[reason] = "Write off"
)


With this, you’ll get two outputs side-by-side  one for the total cost (which returns 350 in the sample data) and the other showing the number of matching records (which is 2 in this case). This way, your full requirement is completely handled. Let me know if you’d like to display both values in the same visual or combine the logic in a more dynamic format

 

Please find the attached pbix file for your reference.

 

 

Best Regards,

Tejaswi.

Community Support

 

 

View solution in original post

4 REPLIES 4
FBergamaschi
Solution Sage
Solution Sage

CALCULATE ( 
            SUM ( Table[cost]),

             Table[Type] = "Underactive",
             Table[dept]= "Claim",
             Table[reason] = "Write off"
)

 

If this helped, please consider giving kudos and mark as a solution

@me in replies or I'll lose your thread

consider voting this Power BI idea

Francesco Bergamaschi

MBA, M.Eng, M.Econ, Professor of BI

@FBergamaschi  this is great to give me the sum, however I also need to to count the number of rows aswell 

Hi @gra_197 ,

Thanks for reaching out to the Microsoft fabric community forum.

 

I’ve revalidated your updated requirement, and you’re absolutely right  the original measure shared above works perfectly to calculate the sum of cost where Type = "Underactive", dept = "Claim" and reason = "Write off". To also include the count of rows matching the same filters, I created a second measure using COUNTROWS inside the same filter logic.

 

Here’s the additiona measure:

Row Count Measure =
CALCULATE (
COUNTROWS ( 'DataTable' ),
'DataTable'[Type] = "Underactive",
'DataTable'[dept] = "Claim",
'DataTable'[reason] = "Write off"
)


With this, you’ll get two outputs side-by-side  one for the total cost (which returns 350 in the sample data) and the other showing the number of matching records (which is 2 in this case). This way, your full requirement is completely handled. Let me know if you’d like to display both values in the same visual or combine the logic in a more dynamic format

 

Please find the attached pbix file for your reference.

 

 

Best Regards,

Tejaswi.

Community Support

 

 

Very easy with another measure

 

CALCULATE ( 
            COUNTROWS ( Table ),

             Table[Type] = "Underactive",
             Table[dept]= "Claim",
             Table[reason] = "Write off"
)

 

If this helped, please consider giving kudos and mark as a solution

@me in replies or I'll lose your thread

consider voting this Power BI idea

Francesco Bergamaschi 

MBA, M.Eng, M.Econ, Professor of BI

Helpful resources

Announcements
September Power BI Update Carousel

Power BI Monthly Update - September 2025

Check out the September 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.