Mysql
 sql >> Base de données >  >> RDS >> Mysql

Utilisation de group_concat

Essayez :

select LOPID,EmpId,
max(case when LOPStatus='Y' then TimeUpdated end) as time_start,
max(case when LOPStatus='N' then TimeUpdated end) as time_end  
from LOPList where JobID= 22 group by LOPID;