select employee,
log_type,
DATE_FORMAT(time,"%Y-%m-%d") as "attendance_date",
case when log_type = 'IN' then TIME_FORMAT(ch.time,"%H:%i:%s") end as check_in ,
case when log_type = 'OUT' then TIME_FORMAT(ch.time,"%H:%i:%s") end as check_out
from Employee_checkin ch
where DATE_FORMAT(time,"%Y-%m-%d") = '2023-02-14'
my result is :
HR-EMP-00001 IN 2023-02-14 09:24:24
HR-EMP-00001 OUT 2023-02-14 15:24:40