Home > Back-end >  How statistics from two time intervals, the employees normal working hours, overtime over the weeken
How statistics from two time intervals, the employees normal working hours, overtime over the weeken

Time:11-16

How statistics from two time intervals, the employees normal working hours, overtime over the weekend, and statutory holiday overtime?

Employees to work time is 8 to 12 PM, 1 PM to 5 PM, 7 PM to 9 PM, go to work five days a week and a half,

Then employees from 14 PM to 10 o 'clock in the morning the next day 10 points to go off work, also is the staff card 2 times, one time is 14 PM, a time is the second day morning 10:10,
After work time,
SQL SERVER 2000,
How to calculate how many hours the employees work at ordinary times?
How many hours work on the weekend (employees may weekends)?
The national legal holiday work how many hours (employee may also be legal holiday overtime?

CodePudding user response:

First you have to make in a year which is a statutory holiday a few days, days is weekend, what day is to be marked at ordinary times, just good statistics

CodePudding user response:

I've seen this type of check on work attendance, the feeling is very complex, and there was company told me to do, but I didn't do a variety of reasons, I speak I probably thinking,
1, set up a legal holiday table, recording the date of holiday inside
2, the staff work time statistics there are three types of time field
3, the application reads the employee's attendance record, judge for the first time attendance time on weekdays or weekend or statutory holiday time periods, in which he took that section of the standard length and the actual long minimum, writes each type of field,
4, across the day I have no idea how to calculate


CodePudding user response:

Have written before attendance related stored procedure, lz, I think you need to add the examples cited another factor to judge, or you won't get the employee of the first and second day commuting time,
Do the most basic of check on work attendance statistics should be the employee's work every day CARDS and work CARDS, then according to the daily commute time, work overtime time, what day is the weekend, what day is legal holiday to count work time at ordinary times, overtime over the weekend, and statutory holiday overtime

CodePudding user response:

Victor_yang said is right, then victor_yang, talk about our treatment across day overtime:
1, across a day to work overtime to apply for, application after the application can be in advance, or else who knows you points is what playing CARDS, more than 10 years with our clock in, with a computer security choose what playing CARDS (go to work, go off work, overtime work, overtime work) which method is very good, but now are fingerprints, face the clock, what the system will set a time to play CARDS;
2, application, the system will know that your 10:10 points been playing CARDS work overtime, and no clock in the morning, and no accounting the clock;
3, overtime calculation, table build a field that is used to time into minutes, such as work at 8 o 'clock, corresponding to 480 minutes, if the cross, the 24 * 60=1440 minutes, plus such minute minus the minutes is the work time to work, work, of course, want to consider the company's working hours, such as clock in, before eight o 'clock at 480 minutes to less, 8:10 clock in, according to 490 minutes,
  • Related