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

Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Learn more

Reply
Matt_JEM
Helper I
Helper I

Total Sum of Visual Table incorrect

Good afternoon All.

 

I have a table where I have filtered out certain SalesOrder numbers. The total of Value of  all the SalesOrders is shown at the bottom. This total is correct if I don't filter out any SalesOrder numbers, but is incorrect if I filter out certain SalesOrder Numbers. How do I fix this so that the total reflects to correct value for the selected line. The correct total is 6 039 954.50 and not as per attached picture.

 

Matt_JEM_0-1733232520654.png

 

I thank you in advance for your help.

 

Regards

 

Matt

6 REPLIES 6

TotalSales =
SUMX (
    SUMMARIZE (
        'SalesTable',
        'SalesTable'[SalesOrder],
        'SalesTable'[Customer],
        'SalesTable'[CustomerPoNumber],
        'SalesTable'[OrderStatus],
        "@SalesValue", [SalesValue]
    ),
    [@SalesValue]
)
Try this measure. Use the table on the 'many' side of the relationship that contains the Sales Value.

Good morning  @Irwan 

 

When I build the visual thable the SalesOrder number comes from a table called " PoNumbersNotInFactory"and the value of the sales comes from a table called " vw_Rep_Sales_BackOrder_Offer". I hope this helps.

 

I thank you in advance for your support.

Anonymous
Not applicable

Hi @Matt_JEM ,

As you mentioned in your reply, there are two tables in your example data.

 

So I think you can give a part of the example data and the relationship between these two tables.

 

 

Best Regards

Yilong Zhou

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

dharmendars007
Super User
Super User

Hello @Matt_JEM , 

To make the total reflect the correct value for the filtered rows, you can modify your measure to account for the filters in the table, adjusted Measure below for Correct Totals

Filtered Total Sales =
SUMX(VALUES(SalesOrder[SalesOrder]),
CALCULATE(SUM(SalesOrder[SalesAmount])))

If you find this helpful , please mark it as solution which will be helpful for others and Your Kudos/Likes 👍 are much appreciated!

 

Thank You

Dharmendar S

LinkedIN 

Good morning Dharmendar S.

 

Thank you for your reply. I get exactly the same result. The problem is not calculating the SalesOrder values, the problem I have is that when I display the values in a visual table, the total displayed at the bottom is the total of all the sales orders and not the total of the sales orders that is left after implementing a filter.

 

I hope this make more sense. Once again thank you for the help.

 

Matt_JEM_0-1733288403523.png

Regards

Matt

hello @Matt_JEM 

 

i am not sure but the Total is just sum of the data above.

so if the Total is not as expected, maybe the filter does not work or the calculation DAX is not working?

 

Thank you.

Helpful resources

Announcements
Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

October Power BI Update Carousel

Power BI Monthly Update - October 2025

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

Top Solution Authors