Discussion:
Weekly Rests
(too old to reply)
Zeeshan Hussain
2007-01-11 14:13:36 UTC
Permalink
Hye

I m working on daily attendance in payroll system, I have to define the
weekly rest of employees. I use DOW() function but I m not understanding
that how can I get the rest dates in one month. Would somebody help me.

regards,

zeeshan
Olaf Doschke
2007-01-13 09:44:04 UTC
Permalink
Hi Zeeshan,

something like determine all weekdays/work days from today
until the end of month?

First determine last day of month by
gomonth(date()-day(date())+1,1)-1
then loop from date() to there and check
with DOW(), if it's a weekday or a weekend
day.

But to also take holidays ino account, it's
much easier to have a table of work days.

Bye, Olaf.

Loading...