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

Earn a 50% discount on the DP-600 certification exam by completing the Fabric 30 Days to Learn It challenge.

Reply
py1029
Frequent Visitor

Incorrect Measure Total

Hi,

 

I have a table as below. The columns of zOreder Qy, zAccum Deliver and zPending are all measures. Value in zPending is obtained by subtracting zAccum Deliver from zOrder Qty (zOrder Qty - zAccum Deliver = zPending). 

 

Would like to ask how to get the correct Total for column zPending? I already tried with SUMMARIZE, SUMX and HASONEVALUE. All of these couldn't give me the correct Total. 

 

Is there any other methods in getting the correct Total? 

 

Thanks. 

 

py1029_1-1637122145209.png

 

2 REPLIES 2
v-yiruan-msft
Community Support
Community Support

Hi @py1029 ,

Please create another new measure as below  and put the new measure onto the table visual to replace the current one [zPending]:

New Measure = SUMX ( VALUES ( 'Table'[PO ID] ), [zPending] )

In addition, you can refer the method in the following links to resolve it.

Why Your Total Is Incorrect In Power BI - The Key DAX Concept To Understand

Dax for Power BI: Fixing Incorrect Measure Totals

If the above ones can't help you get the correct total pending values, please provide some sample data(exclude sensitive data) and the formula of measure [zOrder Qty] and [zAccum Deliver]. Thank you.

Best Regards

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

Hi @v-yiruan-msft 

 

Thanks for your reply. I still couldn't get the correct total pending values with this measure. 

Here attached the sample data and the measures that I used in the table. 

 

py1029_0-1637555884936.png

"Order Qty" is the total quantity ordered for the particular PO. 

"Receipt Date" is the date that received the quantity amount. 

When I select the period (for e.g. Aug-2021):

py1029_1-1637556263530.png

I would like to know the total pending quantity to be delivered for each PO on next month (Sep-2021). 

Hence, I got all these measures to calculate the accumulated delivered quantity until 14th day of each month and pending quantity to be delivered for the next month of period select.

 

py1029_2-1637557860775.png

py1029_3-1637557932480.png

py1029_4-1637558086427.png

py1029_5-1637558144638.png

py1029_6-1637558178673.png

Next, I created a measre to filter the order that left to be delivered on Sep-2021. [First day of the month] would be 1-9-2021 while [Last day of the month] would be 30-Sep-2021. 

py1029_7-1637558335186.png

py1029_8-1637558657674.png

 

py1029_9-1637558906709.png

When I apply new measure to get the total pending values, it still couldn't work. 

Hope the information that I provided might help to understand more. Your help is much appreciated.

Thanks!

Helpful resources

Announcements
PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

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