| Sort (cost=4624.46..4626.96 rows=1000 width=436) |
| Sort Key: (date(tt.dt)) DESC |
| -> Group (cost=4557.13..4574.63 rows=1000 width=436) |
| Group Key: tt.dt, p.day_at, p.user_id |
| -> Sort (cost=4557.13..4559.63 rows=1000 width=420) |
| Sort Key: tt.dt, p.day_at, p.user_id |
| -> Hash Left Join (cost=4494.55..4507.30 rows=1000 width=420) |
| Hash Cond: (date(tt.dt) = p.day_at) |
| -> Function Scan on generate_series tt (cost=0.02..10.02 rows=1000 width=8) |
| -> Hash (cost=4477.21..4477.21 rows=1386 width=412) |
| -> Seq Scan on tbl_punch p (cost=0.00..4477.21 rows=1386 width=412) |
| Filter: (user_id = 1001) |