explain.depesz.com

PostgreSQL's explain analyze made readable

Result: wRdq

Settings
# exclusive inclusive rows x rows loops node
1. 0.000 0.000 ↓ 0.0

Result (cost=153,870.38..153,883.71 rows=1 width=692) (actual rows= loops=)

2. 0.000 0.000 ↓ 0.0

Sort (cost=153,870.38..153,870.38 rows=1 width=628) (actual rows= loops=)

  • Sort Key: ntf.not_fecha_inicio DESC
3. 0.000 0.000 ↓ 0.0

Nested Loop (cost=1.13..153,870.37 rows=1 width=628) (actual rows= loops=)

  • Join Filter: (ca.prcs_id = pr.prcs_id)
4. 0.000 0.000 ↓ 0.0

Nested Loop (cost=1.13..153,844.98 rows=1 width=451) (actual rows= loops=)

  • Join Filter: (ntf.caso_id = (ca.item_key)::numeric)
5. 0.000 0.000 ↓ 0.0

Index Scan using wfa_caso_ind_3 on casos ca (cost=0.42..10,642.29 rows=149 width=363) (actual rows= loops=)

  • Index Cond: (caso_fecha_termino IS NULL)
  • Filter: (prcs_id = (nvl(NULL::character varying, prcs_id))::numeric)
6. 0.000 0.000 ↓ 0.0

Materialize (cost=0.71..143,080.62 rows=41 width=88) (actual rows= loops=)

7. 0.000 0.000 ↓ 0.0

Nested Loop (cost=0.71..143,080.41 rows=41 width=88) (actual rows= loops=)

  • Join Filter: (pac.actividad_id = ntf.actividad_id)
8. 0.000 0.000 ↓ 0.0

Index Scan using wfa_notificacion_n1 on cwfa_notificacion ntf (cost=0.43..142,158.90 rows=13,865 width=47) (actual rows= loops=)

  • Index Cond: ((not_estado)::text = 'OPEN'::text)
  • Filter: (SubPlan 2)
9.          

SubPlan (forIndex Scan)

10. 0.000 0.000 ↓ 0.0

Append (cost=0.42..9.47 rows=2 width=4) (actual rows= loops=)

11. 0.000 0.000 ↓ 0.0

Index Only Scan using wfa_roles_usuarios_pk on cwfa_roles_usuario wur (cost=0.42..8.44 rows=1 width=4) (actual rows= loops=)

  • Index Cond: ((usr_codigo = 'ARKADIOS'::text) AND (rol_nombre = (ntf.not_rol_receptor)::text))
12. 0.000 0.000 ↓ 0.0

Result (cost=0.00..1.01 rows=1 width=4) (actual rows= loops=)

  • One-Time Filter: ('ARKADIOS'::text = (ntf.not_rol_receptor)::text)
13. 0.000 0.000 ↓ 0.0

Seq Scan on dual (cost=0.00..1.01 rows=1 width=4) (actual rows= loops=)

14. 0.000 0.000 ↓ 0.0

Materialize (cost=0.28..89.62 rows=4 width=46) (actual rows= loops=)

15. 0.000 0.000 ↓ 0.0

Nested Loop (cost=0.28..89.60 rows=4 width=46) (actual rows= loops=)

16. 0.000 0.000 ↓ 0.0

Seq Scan on cwfa_actividad act (cost=0.00..39.45 rows=7 width=47) (actual rows= loops=)

  • Filter: (act_version = act_ult_version)
17. 0.000 0.000 ↓ 0.0

Index Scan using wfa_actividades_proceso_n1 on cwfa_actividades_proceso pac (cost=0.28..7.15 rows=1 width=28) (actual rows= loops=)

  • Index Cond: (((item_type)::text = (act.item_type)::text) AND ((act_nombre)::text = (act.act_nombre)::text))
18. 0.000 0.000 ↓ 0.0

Seq Scan on procesos pr (cost=0.00..19.61 rows=461 width=56) (actual rows= loops=)

19.          

SubPlan (forResult)

20. 0.000 0.000 ↓ 0.0

Index Scan using fed_index_n1 on fel_documento (cost=0.42..12.03 rows=1 width=32) (actual rows= loops=)

  • Index Cond: (doc_numero_caso = to_number((ca.item_key)::text))
  • Filter: ((doc_numero_oficio IS NOT NULL) AND (doc_version = doc_ultima_version))