mandelia
asked on
Need a query to exclude weekends.
Greetings Experts,
we can check weekdays by the keyword weekday in the query.
I need a Query in access that does the following:
I have two dates. d1 and d2 in a table a.
So the query should return me the weekdays between two dates. ie it should exclude the weekends.
Fo if d1 = 09/08/2007 and d2 = 01/08/2007
then i should get 6 and not 8
if d1 = 06/07/2007 and d2 = 16/07/2007
i should return 6 and not 10
we can check weekdays by the keyword weekday in the query.
I need a Query in access that does the following:
I have two dates. d1 and d2 in a table a.
So the query should return me the weekdays between two dates. ie it should exclude the weekends.
Fo if d1 = 09/08/2007 and d2 = 01/08/2007
then i should get 6 and not 8
if d1 = 06/07/2007 and d2 = 16/07/2007
i should return 6 and not 10
DateDiff ( "w", date1, date2, [firstdayofweek], [firstweekofyear])
ASKER
In the scenario above what should be [firstdayofweek], [firstweekofyear]
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.