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

Power BI is turning 10! Let’s celebrate together with dataviz contests, interactive sessions, and giveaways. Register now.

Reply
Broeselchen
Helper III
Helper III

Calculated column with a sum

Hello, I need a calculated column with the total sales of each customer. I can't do it in a measure because I need it to eliminate the duplicates for the connection to an other table.

Example:

Broeselchen_0-1673279052929.png

 

1 ACCEPTED SOLUTION
amitchandak
Super User
Super User

@Broeselchen , A new column

 

Sumx(filter(Table, [Customer] = earlier([Customer]) ), [Sales])

Full Power BI Video 20 Hours YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

View solution in original post

5 REPLIES 5
serpiva64
Solution Sage
Solution Sage

Hi, 

you can try this calculated column

Column = var currclient = 'Table'[Column1]
var result = CALCULATE(sumx('Table','Table'[Column2]), FILTER('Table', 'Table'[Column1]=currclient))
return
result
 
serpiva64_0-1673280941653.png

If this post isuseful to help you to solve your issue consider giving the post a thumbs up and accepting it as a solution !

 

Migasuke
Memorable Member
Memorable Member

Hi @Broeselchen ,
If I understand well - you want to have new column with Total Sales, correct?
If yes - please try following formula:

Migasuke_0-1673280293902.png

 



If my answer was helpful please give me a Kudos or even accept as a Solution.

Let's connect on LinkedIn!

Sorry, this didn't work.

Strange that it does not work for you, but I see that amitchandak has some alternative solution.
Good luck with your project!

 



If my answer was helpful please give me a Kudos or even accept as a Solution.

Let's connect on LinkedIn!

amitchandak
Super User
Super User

@Broeselchen , A new column

 

Sumx(filter(Table, [Customer] = earlier([Customer]) ), [Sales])

Full Power BI Video 20 Hours YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

Helpful resources

Announcements
Join our Fabric User Panel

Join our Fabric User Panel

This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.

June 2025 Power BI Update Carousel

Power BI Monthly Update - June 2025

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

June 2025 community update carousel

Fabric Community Update - June 2025

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