explain.depesz.com

PostgreSQL's explain analyze made readable

Result: PErO

Settings
# exclusive inclusive rows x rows loops node
1. 0.009 10,704.387 ↑ 1.0 1 1

Aggregate (cost=9,797.49..9,797.50 rows=1 width=0) (actual time=10,704.386..10,704.387 rows=1 loops=1)

  • Buffers: shared hit=5252287
2. 0.063 10,704.378 ↑ 1.0 1 1

Nested Loop (cost=2.91..9,797.49 rows=1 width=0) (actual time=216.516..10,704.378 rows=1 loops=1)

  • Join Filter: (bei.ent_sta_id = bes.ent_sta_id_auto)
  • Rows Removed by Join Filter: 64
  • Buffers: shared hit=5252287
3. 0.015 10,704.211 ↑ 1.0 1 1

Nested Loop (cost=2.91..9,793.03 rows=1 width=8) (actual time=216.458..10,704.211 rows=1 loops=1)

  • Join Filter: (po.pool_id_auto = up.pool_id)
  • Buffers: shared hit=5252285
4. 684.773 10,704.159 ↑ 1.0 1 1

Nested Loop (cost=2.62..9,792.71 rows=1 width=16) (actual time=216.417..10,704.159 rows=1 loops=1)

  • Buffers: shared hit=5252282
5. 1,008.176 8,077.278 ↓ 485,527.0 485,527 1

Nested Loop (cost=2.20..9,789.39 rows=1 width=16) (actual time=5.665..8,077.278 rows=485,527 loops=1)

  • Buffers: shared hit=3306103
6. 750.227 6,098.048 ↓ 242,763.5 485,527 1

Merge Join (cost=1.92..9,788.78 rows=2 width=12) (actual time=5.629..6,098.048 rows=485,527 loops=1)

  • Merge Cond: (pe.tsk_id = t.tsk_id_auto)
  • Buffers: shared hit=2335048
7. 1,370.592 5,011.960 ↓ 69,361.1 485,528 1

Nested Loop (cost=1.55..34,222.33 rows=7 width=20) (actual time=5.592..5,011.960 rows=485,528 loops=1)

  • Join Filter: ((p.pro_id_auto = pi.pro_id) AND (p.pro_ver_id = pi.pro_ver_id))
  • Buffers: shared hit=2335042
8. 617.842 1,350.504 ↓ 250.0 572,716 1

Nested Loop (cost=1.12..32,445.85 rows=2,291 width=44) (actual time=5.574..1,350.504 rows=572,716 loops=1)

  • Join Filter: ((p.pro_id_auto = pei.pro_id) AND (p.pro_ver_id = pei.pro_ver_id))
  • Buffers: shared hit=40980
9. 5.529 19.327 ↑ 2.1 3,115 1

Nested Loop (cost=0.56..3,017.77 rows=6,496 width=32) (actual time=0.048..19.327 rows=3,115 loops=1)

  • Buffers: shared hit=8481
10. 4.453 4.453 ↑ 2.5 3,115 1

Index Scan using ix_pro_element_01 on pro_element pe (cost=0.28..567.08 rows=7,699 width=20) (actual time=0.028..4.453 rows=3,115 loops=1)

  • Index Cond: (env_id = 1001)
  • Buffers: shared hit=2219
11. 9.345 9.345 ↑ 1.0 1 3,115

Index Only Scan using pk_process on process p (cost=0.28..0.31 rows=1 width=12) (actual time=0.002..0.003 rows=1 loops=3,115)

  • Index Cond: ((env_id = 1001) AND (pro_id_auto = pe.pro_id) AND (pro_ver_id = pe.pro_ver_id))
  • Heap Fetches: 0
  • Buffers: shared hit=6262
12. 713.335 713.335 ↓ 184.0 184 3,115

Index Only Scan using ix_pro_ele_inst_status on pro_ele_instance pei (cost=0.56..4.52 rows=1 width=24) (actual time=0.007..0.229 rows=184 loops=3,115)

  • Index Cond: ((pro_ele_inst_status = 'R'::text) AND (pro_ver_id = pe.pro_ver_id) AND (pro_id = pe.pro_id) AND (pro_ele_id = pe.pro_ele_id_auto) AND (env_id = 1001))
  • Heap Fetches: 17739
  • Buffers: shared hit=32499
13. 2,290.864 2,290.864 ↑ 1.0 1 572,716

Index Scan using pk_pro_instance on pro_instance pi (cost=0.43..0.76 rows=1 width=20) (actual time=0.004..0.004 rows=1 loops=572,716)

  • Index Cond: ((env_id = 1001) AND (pro_inst_id_auto = pei.pro_inst_id))
  • Filter: (((pro_inst_status)::text <> 'S'::text) AND ((pro_inst_name_pre)::text = 'DPA'::text) AND (pei.pro_id = pro_id) AND (pei.pro_ver_id = pro_ver_id))
  • Rows Removed by Filter: 0
  • Buffers: shared hit=2294062
14. 335.861 335.861 ↓ 5,712.2 485,535 1

Index Only Scan using pk_task on task t (cost=0.14..9.63 rows=85 width=8) (actual time=0.016..335.861 rows=485,535 loops=1)

  • Index Cond: (env_id = 1001)
  • Heap Fetches: 485535
  • Buffers: shared hit=6
15. 971.054 971.054 ↑ 1.0 1 485,527

Index Only Scan using pk_pool on pool po (cost=0.28..0.29 rows=1 width=4) (actual time=0.002..0.002 rows=1 loops=485,527)

  • Index Cond: (pool_id_auto = pei.pool_id)
  • Heap Fetches: 0
  • Buffers: shared hit=971055
16. 1,942.108 1,942.108 ↓ 0.0 0 485,527

Index Scan using ix_bus_ent_instance_05 on bus_ent_instance bei (cost=0.42..3.31 rows=1 width=12) (actual time=0.004..0.004 rows=0 loops=485,527)

  • Index Cond: (bus_ent_inst_id_auto = pi.bus_ent_inst_id)
  • Filter: ((att_value_9 IS NULL) AND ((att_value_5)::text ~~ '24-09-2019 12:35'::text) AND (env_id = 1001) AND (bus_ent_id = 1006) AND (upper((att_value_6)::text) = '147'::text))
  • Rows Removed by Filter: 1
  • Buffers: shared hit=1946179
17. 0.037 0.037 ↑ 1.0 1 1

Index Scan using pk_usr_pool on usr_pool up (cost=0.28..0.31 rows=1 width=4) (actual time=0.035..0.037 rows=1 loops=1)

  • Index Cond: (((usr_login)::text = '12312693'::text) AND (pool_id = pei.pool_id))
  • Filter: (reg_status = 0)
  • Buffers: shared hit=3
18. 0.104 0.104 ↑ 1.0 65 1

Seq Scan on bus_ent_status bes (cost=0.00..3.64 rows=65 width=8) (actual time=0.018..0.104 rows=65 loops=1)

  • Filter: ((env_id = 1001) AND ((ent_sta_name)::text <> ALL ('{EXTINGUIDO,NC_UNIFICADO,NC_ARCHIVADA,NC_ARCHIVADA_DIFINITIVA,NC_FOTO_SGSP_ALTA,NC_FOTO_SIPPAU,NC_PENDIENTE_PROCESAR,NC_ELIMINADA}'::text[])))
  • Rows Removed by Filter: 8
  • Buffers: shared hit=2
Planning time : 36.979 ms
Execution time : 10,704.867 ms