![]() |
Working days in MS Query
I need to calculate NETWORKDAYS which works fine in Excel but I need to do it
in MS Query. Is there a formula? |
Working days in MS Query
See if this helps....
This MS Query SQL returns: The count of workdays (mon thru fri) by Name from the tblDatesNames table where dates are between 01-JAN-2008 and 25-JAN-2008 SELECT tblDatesNames.Name, Count(tblDatesNames.Date) FROM `C:\Sandbox1`.tblDatesNames tblDatesNames WHERE (weekday(Date) Between 2 And 6) AND (tblDatesNames.Date Between cdate('01-JAN-2008') And cdate('25-JAN-2008')) GROUP BY tblDatesNames.Name The returned values list looks like this: Name Expr1001 Alpha 4 Bravo 4 Charlie 4 Delta 4 Echo 2 Golf 2 Hotel 4 India 4 Juliet 4 Kilo 4 Lima 2 Is that something you can work with? Post back if you have more questions. Regards, Ron Microsoft MVP - Excel "mcquam" wrote in message ... I need to calculate NETWORKDAYS which works fine in Excel but I need to do it in MS Query. Is there a formula? |
All times are GMT +1. The time now is 04:48 PM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com