Ad Code

Query to generate Employee absent report for a given range of dates

Please give advice about bellow query

 SELECT
    m.id, m.employee_code, m.fullname, d.attendance_date

FROM
    hrm_employee_basic_info as m,
    (select distinct attendance_date from hrm_employee_attendance where attendance_date between '2015-04-01' and '2015-04-09') as d

WHERE
    m.id not in (select employee_id from hrm_employee_attendance where attendance_date=d.attendance_date)

ORDER BY
    m.id



Post a Comment

0 Comments