弹性考勤记录查询SQL如何查询指定时间段内的考勤记录?

弹性考勤记录查询sql

SELECT employee_id, check_in_time, check_out_time
FROM attendance_records
WHERE
(check_in_time >= ‘2024-01-01 00:00:00’ AND check_in_time <= ‘2024-01-01 23:59:59’)
OR (check_out_time >= ‘2024-01-01 00:00:00’ AND check_out_time <= ‘2024-01-01 23:59:59’)
OR (check_in_time < ‘2024-01-01 00:00:00’ AND check_out_time > ‘2024-01-01 23:59:59’);

利唐i人事HR社区,发布者:HR数字化研究员,转转请注明出处:https://www.ihr360.com/hrnews/20241224242.html

(0)
上一篇 18小时前
下一篇 18小时前

相关推荐