Ver originalSELECT Empleado, CAST(DateDiff(DAY,0,Fechahora) AS DateTime) Fecha, DateDiff(HOUR,MIN(Fechahora),MAX(Fechahora))FROM Mi TablaGROUP BY Empleado, CAST(DateDiff(DAY,0,Fechahora) AS DateTime);