QUERY PLAN
Aggregate (cost=330.25..330.26 rows=1 width=32)
-> Append (cost=0.00..328.88 rows=547 width=5)
-> Subquery Scan on "*SELECT* 1" (cost=0.00..319.52 rows=513 width=5)
-> Seq Scan on tbl_erp_cash_cost_tickets r (cost=0.00..314.39 rows=513 width=13)
Filter: (is_payment_settle AND (bank_settle_at >= '2025-01-01 00:00:00+08'::timestamp with time zone) AND (bank_settle_at <= '2025-12-31 23:59:59+08'::timestamp with time zone) AND (status = 2))
-> Subquery Scan on "*SELECT* 2" (cost=0.00..2.71 rows=24 width=5)
-> Seq Scan on tbl_erp_cost_tickets r_1 (cost=0.00..2.47 rows=24 width=13)
Filter: ((created_at >= '2025-01-01 00:00:00+08'::timestamp with time zone) AND (created_at <= '2025-12-31 23:59:59+08'::timestamp with time zone) AND (status = 2))
-> Subquery Scan on "*SELECT* 3" (cost=0.00..1.08 rows=1 width=32)
-> Seq Scan on tbl_erp_cost_convert_tickets r_2 (cost=0.00..1.07 rows=1 width=40)
Filter: ((created_at >= '2025-01-01 00:00:00+08'::timestamp with time zone) AND (created_at <= '2025-12-31 23:59:59+08'::timestamp with time zone) AND (status = 2))
-> Subquery Scan on "*SELECT* 4" (cost=0.00..1.24 rows=5 width=3)
-> Seq Scan on tbl_erp_wage_tickets r_3 (cost=0.00..1.19 rows=5 width=11)
Filter: ((created_at >= '2025-01-01 00:00:00+08'::timestamp with time zone) AND (created_at <= '2025-12-31 23:59:59+08'::timestamp with time zone) AND (status = 2))
-> Subquery Scan on "*SELECT* 5" (cost=0.00..1.11 rows=1 width=32)
-> Seq Scan on tbl_erp_social_insurances r_4 (cost=0.00..1.10 rows=1 width=40)
Filter: ((created_at >= '2025-01-01 00:00:00+08'::timestamp with time zone) AND (created_at <= '2025-12-31 23:59:59+08'::timestamp with time zone) AND (status = 2))
-> Subquery Scan on "*SELECT* 6" (cost=0.00..1.06 rows=1 width=32)
-> Seq Scan on tbl_erp_provident_funds r_5 (cost=0.00..1.05 rows=1 width=40)
Filter: ((created_at >= '2025-01-01 00:00:00+08'::timestamp with time zone) AND (created_at <= '2025-12-31 23:59:59+08'::timestamp with time zone) AND (status = 2))
-> Subquery Scan on "*SELECT* 7" (cost=0.00..1.08 rows=1 width=32)
-> Seq Scan on tbl_erp_personal_taxs r_6 (cost=0.00..1.07 rows=1 width=40)
Filter: ((created_at >= '2025-01-01 00:00:00+08'::timestamp with time zone) AND (created_at <= '2025-12-31 23:59:59+08'::timestamp with time zone) AND (status = 2))
-> Subquery Scan on "*SELECT* 8" (cost=0.00..1.06 rows=1 width=32)
-> Seq Scan on tbl_erp_wage_prizes r_7 (cost=0.00..1.05 rows=1 width=40)
Filter: ((created_at >= '2025-01-01 00:00:00+08'::timestamp with time zone) AND (created_at <= '2025-12-31 23:59:59+08'::timestamp with time zone) AND (status = 2))