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
Mopadii
New Member

Combine VALUES and FILTER

Hi all,

Can you please support with the following DAX.

I try to calculate networking day between 2 dates, excluding holidays and weekend.
My holidays table is multi-dimensional, it covers every countries. I tried this but it is not a valid syntax...

= NETWORDAYS( _startdate, _enddate, 1, VALUES(date, country = "FR"))

Best.

 

1 ACCEPTED SOLUTION
lbendlin
Super User
Super User

 

=
NETWORKDAYS (
    _startdate,
    _enddate,
    1,
    DISTINCT (
        SELECTCOLUMNS ( FILTER ( 'Holidays', [country] = "FR"),"Date",[date] ) )
    )
)

View solution in original post

2 REPLIES 2
lbendlin
Super User
Super User

 

=
NETWORKDAYS (
    _startdate,
    _enddate,
    1,
    DISTINCT (
        SELECTCOLUMNS ( FILTER ( 'Holidays', [country] = "FR"),"Date",[date] ) )
    )
)

Just trying your solution and it works well. Little bit tricky but I will remember the tips.

thanks a lot for your help 🙂

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.