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

Compete to become Power BI Data Viz World Champion! First round ends August 18th. Get started.

Reply
Freekh
Frequent Visitor

Matrix row total not matching values

Hi,

 

I can't seem to calculate the correct weektotal. The values calculated per day are correct and need to be summed per week.

 

This is the formule is use:

Freekh_1-1638364121334.png

 

Below the values which are returned:

Freekh_0-1638363798360.png

 

The total I am looking for is 17+24+13+5+2 = 61

 

Is there a way to calculate this total?

 

1 ACCEPTED SOLUTION
AlexisOlson
Super User
Super User

Try moving your first three variables inside so they are calculated for each date separately.

 

# Rest Pallets =
SUMX (
    ADDCOLUMNS (
        SUMMARIZE ( fct_Scanning, dimDate[Date], fct_Scanning[DC] ),
        "RestPallets",
            CALCULATE (
                VAR Pallets = [...]
                VAR FTL = [...]
                VAR WholeFTL = [...]
                RETURN
                    IF ( [...] )
            )
    ),
    [RestPallets]
)

View solution in original post

2 REPLIES 2
AlexisOlson
Super User
Super User

Try moving your first three variables inside so they are calculated for each date separately.

 

# Rest Pallets =
SUMX (
    ADDCOLUMNS (
        SUMMARIZE ( fct_Scanning, dimDate[Date], fct_Scanning[DC] ),
        "RestPallets",
            CALCULATE (
                VAR Pallets = [...]
                VAR FTL = [...]
                VAR WholeFTL = [...]
                RETURN
                    IF ( [...] )
            )
    ),
    [RestPallets]
)

Hi @AlexisOlson

 

Thanks a lot

 

It works!

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.