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

Grow your Fabric skills and prepare for the DP-600 certification exam by completing the latest Microsoft Fabric challenge.

Reply
JonGunnar
Frequent Visitor

Total sum not correct (measure in table again)

Hi, I know this is a very common theme and even though I've been reading some of the articles I can't figure out how to solve this.

 

I'm recalculating some invoice lines due to change of price (using parameter), measures "Sum NO1 N" etc. Then I gather them in measure "Adjusted". Finally I want new total sum in Measure "New line amount". 

 

New line amount = IF([Adjusted] = BLANK(),CALCULATE(SUM('Spørring1'[LINE AMOUNT])),[Adjusted])
 
As you see my unchaged values are not included in "New line amount" total sum. I need the total to be correct. How to do this? And sorry for bringing this "total sum issue" up again.
 
Regards JGPic.PNG
1 ACCEPTED SOLUTION
PaulDBrown
Community Champion
Community Champion

Try:
with totals = SUMX (Table, [New line amount])





Did I answer your question? Mark my post as a solution!
In doing so, you are also helping me. Thank you!

Proud to be a Super User!
Paul on Linkedin.






View solution in original post

2 REPLIES 2
PaulDBrown
Community Champion
Community Champion

Try:
with totals = SUMX (Table, [New line amount])





Did I answer your question? Mark my post as a solution!
In doing so, you are also helping me. Thank you!

Proud to be a Super User!
Paul on Linkedin.






amitchandak
Super User
Super User

@JonGunnar , You need to change measure like example

 

New line amount = sumx(summarize(Table, Table[Kanledar_kontraktna], Table[Year], Table[period], "_1",IF([Adjusted] = BLANK(),CALCULATE(SUM('Spørring1'[LINE AMOUNT])),[Adjusted])),[_1])

 

Correct the column name, and add un summarized column in summarize, if needed

Helpful resources

Announcements
RTI Forums Carousel3

New forum boards available in Real-Time Intelligence.

Ask questions in Eventhouse and KQL, Eventstream, and Reflex.

MayPowerBICarousel1

Power BI Monthly Update - May 2024

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