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

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
Anonymous
Not applicable

summarize with multiple filter

Good evening everyone!

 

I havent been able to solve a DAX sintax. I need to create a table with some columns from a bigger table. However, I need to bring data by two conditions. 

 

The first is condition is to bring all data that says "yes" in the signed off column. And the second condition is to bring the last value updated when encountered the same client twice for the same country (my example 2 times for colombia)

Gretelruiz0423_0-1628113010783.png 

Gretelruiz0423_1-1628113226264.png

 

 

 

I´ve been using this code but its not working. What am I doing wrong? I would appreciate any feedbak. Thanks in advance. 

 

TPCC Clients = CALCULATETABLE(sumamrize(FILTER('Share Point',max('Share Point'[Created]) && CONTAINSSTRING('Share Point'[Signed Off], "yes")),'Share Point'[Region],'Share Point'[Delivery Countries],'Share Point'[Client Holding Name],'Share Point'[Created])
1 ACCEPTED SOLUTION
d_gosbell
Super User
Super User

You are not comparing the max of the Created column with anything, so to convert the max date to a boolean expression it will be treating 0 as false and non-zero as true, so all your rows will match that condition. You could use a variable to capture the max value and then compare it to the created value for the current row.

 

eg

 

TPCC Clients =
SUMMARIZE (
    FILTER (
        'Share Point',
        VAR maxCreated =
            MAX ( 'Share Point'[Created] )
        RETURN
            'Share Point'[Created] = maxCreated
                && CONTAINSSTRING ( 'Share Point'[Signed Off], "yes" )
    ),
    'Share Point'[Region],
    'Share Point'[Delivery Countries],
    'Share Point'[Client Holding Name],
    'Share Point'[Created]
)

View solution in original post

1 REPLY 1
d_gosbell
Super User
Super User

You are not comparing the max of the Created column with anything, so to convert the max date to a boolean expression it will be treating 0 as false and non-zero as true, so all your rows will match that condition. You could use a variable to capture the max value and then compare it to the created value for the current row.

 

eg

 

TPCC Clients =
SUMMARIZE (
    FILTER (
        'Share Point',
        VAR maxCreated =
            MAX ( 'Share Point'[Created] )
        RETURN
            'Share Point'[Created] = maxCreated
                && CONTAINSSTRING ( 'Share Point'[Signed Off], "yes" )
    ),
    'Share Point'[Region],
    'Share Point'[Delivery Countries],
    'Share Point'[Client Holding Name],
    'Share Point'[Created]
)

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

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.