Microsoft Power BI - Addend Analytics

How to Use the NETWORKDAYS DAX Function in Power BI

In Power BI’s DAX language, you can use the NETWORKDAYS function to calculate the number of working days between two dates, excluding weekends and optionally specified holidays.

Syntax: NETWORKDAYS(<start_date>, <end_date>[, <weekend>, <holidays>])


A screenshot of a computer

Description automatically generated

Step 1:-
 Pick the visual “Table” Drag the OrderID, OrderDate, ShippedDate, and HolidayList from the field section to the value field.

A screenshot of a computer

Description automatically generated

Step 2:- Calculate the working weekdays with the help of the Networkdays function.


No. of working days =

VAR start_date = SELECTEDVALUE(Orders[OrderDate])

VAR end_date   = SELECTEDVALUE(Orders[ShippedDate])

RETURN NETWORKDAYS(start_date, end_date, 1, holiday)

Note: I’ve loaded the Holiday list Table on the Power BI desktop since the holiday parameter requires a column table.



Step 3:-
 Drag the measure in the Table Visual.

This would return the number of business days, excluding weekends and specified holidays, that passed between the order date and the shipped date.

The NETWORKDAYS function is one of those underappreciated yet mission-critical functions within Power BI’s DAX (Data Analysis Expressions) language.

For any organization that deals with timelines, delivery metrics, logistics, or employee productivity tracking, calculating working days excluding weekends and holidays is vital.

In Excel, many users are familiar with NETWORKDAYS() for calculating business days. Now, with Power BI’s DAX language, the same function offers enterprise-grade scalability within your data models, allowing you to apply it dynamically across millions of records and complex relationships.

From supply chain analytics and project management dashboards to HR attendance reporting and financial period calculations, NETWORKDAYS helps analysts move beyond simple date differences to true business-time intelligence.

Understanding the NETWORKDAYS Syntax in Power BI

The NETWORKDAYS(<start_date>, <end_date>[, <weekend>, <holidays>]) function takes up to four parameters:

  1. Start_Date: The starting date of your calculation (e.g., order or project start).
  2. End_Date: The end date (e.g., shipping, completion, or delivery date).
  3. Weekend (Optional): You can define which days are treated as weekends.
    • Default value 1 assumes Saturday and Sunday are weekends.
    • You can customize this for countries with different workweeks.
  4. Holidays (Optional): A table column that contains holiday dates to exclude.

The function then calculates the number of working days between the two dates, excluding weekends and the specified holidays.

Practical Example: Calculating Working Days Between Order and Shipping

In your example, you’ve created a measure using DAX:

No. of working days =

VAR start_date = SELECTEDVALUE(Orders[OrderDate])

VAR end_date   = SELECTEDVALUE(Orders[ShippedDate])

RETURN NETWORKDAYS(start_date, end_date, 1, holiday)

This logic dynamically calculates the number of working days between the Order Date and Shipped Date for each record in your Orders table.

Using SELECTEDVALUE() ensures that the calculation responds dynamically to slicers and filters on your Power BI report, meaning it automatically recalculates for any specific order, customer, or date range selected by the user.

 Advanced Use Cases for NETWORKDAYS in Power BI

The versatility of NETWORKDAYS goes far beyond simple order-shipping calculations. Here are some advanced business intelligence applications:

  1. Employee Productivity Tracking: Calculate the number of working days employees spent on specific projects or between assigned and completed tasks.
  1. SLA and Customer Service Metrics: Measure response and resolution times for support tickets while excluding non-working days.
  1. Project Management Dashboards: Visualize project durations in working days rather than calendar days to better reflect team performance.
  1. Finance and Accounting Close Calendars: Compute working days between transaction date and payment date to track payment cycle efficiency.
  1. Manufacturing and Logistics Analytics: Assess lead time between production order and dispatch while accounting for holidays or plant shutdowns.

In each of these scenarios, NETWORKDAYS ensures that your KPIs reflect real operational time, a critical distinction in business performance analysis.

Combining NETWORKDAYS with Other DAX Functions

For even richer insights, combine NETWORKDAYS with complementary DAX date and time functions such as:

  • DATEDIFF() – To compare calendar days versus working days.
  • WEEKDAY() – To dynamically classify weekends.
  • CALCULATE() – To filter working days for specific categories.
  • IF() / SWITCH() – To handle conditional business rules (e.g., half-days).

Example:

WorkingDays_Diff = DATEDIFF(Orders[OrderDate], Orders[ShippedDate], DAY)

Net_WorkingDays = [WorkingDays_Diff] – [NonWorkingDays]

Such combinations allow analysts to create customized working time models aligned with specific company calendars or geographies.

Business Value: Turning Time Calculations into Insights

Accurate working day calculations unlock tangible business benefits:

  • Improved operational forecasting: Predict delivery timelines with precision.
  • Enhanced SLA monitoring: Ensure on-time performance metrics are reliable.
  • Data-driven staffing decisions: Identify bottlenecks based on true working capacity.
  • Cross-functional transparency: Enable consistent date-based metrics across departments.

Organizations using Addend Analytics’ Power BI DAX frameworks can standardize these metrics across reports, ensuring unified definitions of “working day” across HR, logistics, and finance.

Addend Analytics Perspective: Building Smarter Power BI Models

At Addend Analytics, we help organizations design DAX-powered models that convert complex business logic into actionable intelligence.

Our Power BI consulting team specializes in:

  • Designing date intelligence frameworks using functions like NETWORKDAYS, DATEDIFF, and WORKDAY.
  • Automating time-based KPIs for sales, HR, and operations teams.
  • Integrating Power BI with Microsoft Fabric, Azure SQL, and Business Central for scalable analytics solutions.

CTA: Want to leverage DAX functions like NETWORKDAYS for smarter, faster decision-making?
Book your free consultation with Addend Analytics today.
Discover how we transform Power BI dashboards into data-driven business accelerators.

Facebook
Twitter
LinkedIn

Addend Analytics is a Microsoft Gold Partner based in Mumbai, India, and a branch office in the U.S.

Addend has successfully implemented 100+ Microsoft Power BI and Business Central projects for 100+ clients across sectors like Financial Services, Banking, Insurance, Retail, Sales, Manufacturing, Real estate, Logistics, and Healthcare in countries like the US, Europe, Switzerland, and Australia.

Get a free consultation now by emailing us or contacting us.