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

Score big with last-minute savings on the final tickets to FabCon Vienna. Secure your discount

Reply
stefani_vileva
Resolver II
Resolver II

Sum of group by with filter

Hello everyone, 

 

I have problem with calculating the sum of all the mistakes group by order numbers based on every user. I have the following table:

User IDMistakesOrder nrBoxesDate
1234555126.07.2023
1234555426.07.2023
2345657325.07.2023

 

I would like to get the following table

DateUser IDMistakes
26.07.20231234
25.07.20232345

 

I have tried with the following formula but every time I get the values summed by order number. 

 

Mistakes count = 
CALCULATE(
     SUM('Scanned items'[Mistakes]),
     ALLEXCEPT('Scanned items', 'Scanned items'[Order nr]),
     CROSSJOIN('All users', 'Scanned items')
)

 

I am cross joining the tables because in the tables All users I have the names of the users in the system.

Thank you in advance for your help.

 

Kind regards,

Stefani

1 ACCEPTED SOLUTION
Anonymous
Not applicable

Hi @stefani_vileva ,

 

According to your description, here are my steps you can follow as a solution.

(1) My test data is the same as yours.

(2) We can create a table.

New table = 
SUMMARIZE(
    'Scanned items',
    'Scanned items'[Date],
    'Scanned items'[User ID],
    'Scanned items'[Mistakes]
)

(3) Then the result is as follows.

vtangjiemsft_0-1690508837934.png

 

If the above one can't help you get the desired result, please provide some sample data in your tables (exclude sensitive data) with Text format and your expected result with backend logic and special examples. It is better if you can share a simplified pbix file. Thank you.

 

Best Regards,

Neeko Tang

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

2 REPLIES 2
Anonymous
Not applicable

Hi @stefani_vileva ,

 

According to your description, here are my steps you can follow as a solution.

(1) My test data is the same as yours.

(2) We can create a table.

New table = 
SUMMARIZE(
    'Scanned items',
    'Scanned items'[Date],
    'Scanned items'[User ID],
    'Scanned items'[Mistakes]
)

(3) Then the result is as follows.

vtangjiemsft_0-1690508837934.png

 

If the above one can't help you get the desired result, please provide some sample data in your tables (exclude sensitive data) with Text format and your expected result with backend logic and special examples. It is better if you can share a simplified pbix file. Thank you.

 

Best Regards,

Neeko Tang

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

Hello @Anonymous ,

 

Thank you for your help. I solved the problem using a similar approach by grouping them in the power query, but in the end we have the same result.

 

Thanks a lot. 

Kind regards,

Stefani

Helpful resources

Announcements
August Power BI Update Carousel

Power BI Monthly Update - August 2025

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

August 2025 community update carousel

Fabric Community Update - August 2025

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

Top Solution Authors