What is the way to find business days between two specified dates in MySQL?


With the help of DATEDIFF(expr1, expr2) we can find the business days between two specified dates.

For example, if we want to find business days between ‘2017-05-27’ and ‘2017-05-23’ then following would be MySQL query −

mysql> Select DATEDIFF('2017-05-27','2017-05-23') AS 'Total Business Days';
+----------------------+
| Total Business Days  |
+----------------------+
| 4                    |
+----------------------+
1 row in set (0.00 sec)

Updated on: 28-Jan-2020

579 Views

Kickstart Your Career

Get certified by completing the course

Get Started
Advertisements