| Aggregate (cost=1353.58..1353.59 rows=1 width=16) |
| -> Append (cost=455.81..1352.21 rows=549 width=16) |
| -> Hash Join (cost=455.81..819.73 rows=485 width=16) |
| Hash Cond: (ir.case_id = c.id) |
| -> Seq Scan on tbl_implement_records ir (cost=0.00..360.69 rows=770 width=20) |
| Filter: ((NOT is_draft) AND (arrived_at >= '2025-01-01 00:00:00+08'::timestamp with time zone) AND (arrived_at <= '2025-12-31 23:59:59+08'::timestamp with time zone)) |
| -> Hash (cost=391.06..391.06 rows=5180 width=4) |
| -> Seq Scan on tbl_cases c (cost=0.00..391.06 rows=5180 width=4) |
| Filter: (deduct_points_from = ANY ('{5329,5332,5448,5420,1001,5087,5300,5311,5295,1013,1004,1005,5449}'::integer[])) |
| -> Hash Join (cost=96.28..526.99 rows=64 width=16) |
| Hash Cond: (c_1.id = ps.case_id) |
| -> Seq Scan on tbl_cases c_1 (cost=0.00..391.06 rows=5180 width=4) |
| Filter: (deduct_points_from = ANY ('{5329,5332,5448,5420,1001,5087,5300,5311,5295,1013,1004,1005,5449}'::integer[])) |
| -> Hash (cost=95.00..95.00 rows=102 width=20) |
| -> Seq Scan on tbl_pre_sales ps (cost=0.00..95.00 rows=102 width=20) |
| Filter: ((NOT is_draft) AND (start_at >= '2025-01-01 00:00:00+08'::timestamp with time zone) AND (start_at <= '2025-12-31 23:59:59+08'::timestamp with time zone)) |