explain.depesz.com

PostgreSQL's explain analyze made readable

Result: N3AA

Settings
# exclusive inclusive rows x rows loops node
1. 1.288 147.026 ↑ 1.0 1 1

Aggregate (cost=884,253.40..884,253.41 rows=1 width=24) (actual time=147.026..147.026 rows=1 loops=1)

2. 18.500 145.738 ↑ 3.1 11,649 1

Merge Join (cost=0.58..884,162.53 rows=36,347 width=24) (actual time=0.028..145.738 rows=11,649 loops=1)

  • Merge Cond: (r.id = rt.parent_id)
  • Join Filter: ((r.signer_enterprise_id = '3176cd78-0acf-467e-aa51-6cdc7960d0a6'::uuid) OR (alternatives: SubPlan 1 or hashed SubPlan 2))
  • Rows Removed by Join Filter: 4
3. 39.271 39.271 ↓ 1.0 38,966 1

Index Scan using t_resolution_pkey on t_resolution r (cost=0.29..6,747.86 rows=38,937 width=32) (actual time=0.008..39.271 rows=38,966 loops=1)

  • Filter: ((NOT del_rec) AND controlling)
  • Rows Removed by Filter: 5143
4. 35.288 35.288 ↑ 2.9 15,106 1

Index Scan using t_resolution_task_parent_id_idx on t_resolution_task rt (cost=0.29..4,979.52 rows=43,970 width=56) (actual time=0.007..35.288 rows=15,106 loops=1)

  • Filter: ((NOT del_rec) AND (COALESCE(prolongation_date, outer_limit, inner_limit) IS NOT NULL) AND (work_status <> ALL ('{7,13}'::integer[])))
  • Rows Removed by Filter: 29388
5.          

SubPlan (forMerge Join)

6. 0.000 0.000 ↓ 0.0 0

Index Scan using t_resolution_task_executer_parent_id_idx on t_resolution_task_executer rte (cost=0.42..44.64 rows=2 width=0) (never executed)

  • Index Cond: (parent_id = rt.id)
  • Filter: ((NOT del_rec) AND (work_status <> ALL ('{7,13}'::integer[])) AND (enterprise_id = '3176cd78-0acf-467e-aa51-6cdc7960d0a6'::uuid))
7. 52.679 52.679 ↑ 1.0 39,897 1

Seq Scan on t_resolution_task_executer rte_1 (cost=0.00..7,092.84 rows=40,256 width=16) (actual time=0.008..52.679 rows=39,897 loops=1)

  • Filter: ((NOT del_rec) AND (work_status <> ALL ('{7,13}'::integer[])) AND (enterprise_id = '3176cd78-0acf-467e-aa51-6cdc7960d0a6'::uuid))
  • Rows Removed by Filter: 160814