explain.depesz.com

PostgreSQL's explain analyze made readable

Result: NzMTL

Settings
# exclusive inclusive rows x rows loops node
1. 0.004 1.643 ↓ 16.0 16 1

Unique (cost=928.96..928.98 rows=1 width=89) (actual time=1.637..1.643 rows=16 loops=1)

  • rows=16 loops=1)
  • Planning time: 1.381 ms
  • Execution time: 1.745 ms
2. 1.177 1.639 ↓ 16.0 16 1

Sort (cost=928.96..928.96 rows=1 width=89) (actual time=1.637..1.639 rows=16 loops=1)

  • Sort Key: plan_instruction.plan_instruction_orderby, clinical_elements.clinical_elements_gwid, c
  • Sort Method: quicksort Memory: 27kB
  • -> Nested Loop Left Join (cost=923.30..928.95 rows=1 width=89) (actual time=1.457..1.606 rows=
  • -> Nested Loop Left Join (cost=923.30..927.35 rows=1 width=88) (actual time=1.450..1.508
  • -> Unique (cost=668.32..668.34 rows=1 width=77) (actual time=1.441..1.449 rows=16
  • -> Sort (cost=668.32..668.32 rows=1 width=77) (actual time=1.441..1.446 rows
  • Sort Key: clinical_elements.clinical_elements_gwid, clinical_elements.cl
  • Sort Method: quicksort Memory: 27kB
  • -> Nested Loop (cost=53.05..668.31 rows=1 width=77) (actual time=0.613
  • Join Filter: ((clinical_element_template_mapping.clinical_element_
  • -> Nested Loop (cost=52.76..665.74 rows=2 width=44) (actual time
  • -> Bitmap Heap Scan on clinical_element_template_mapping (
  • Recheck Cond: (clinical_element_template_mapping_templ
  • Filter: (((clinical_element_template_mapping_gwid)::te
  • Rows Removed by Filter: 2626
  • Heap Blocks: exact=106
  • Index Cond: ((plan_instruction_gwid)::text = (clinical_element_template_mapping.clinical_element_template_mapping_gwid)::text)
3. 0.046 0.190 ↑ 1.0 2,642 1

Bitmap Index Scan on clinical_element_template_mapping_templateid_index1 (cost=0.00..52.48 rows=2,692 width=0) (actual time=0.190..0.190 rows=2,642 loops=1)

4. 0.144 0.144 ↑ 1.0 1 16

Index Cond: (clinical_element_template_mapping_templateid = 3764) -> Index Scan using plan_instruction_gwid_index on plan_instruction (cost=0.28..7.73 rows=1 width=25) (actual time=0.009..0.009 rows=1 loops=16)

5. 0.160 0.160 ↑ 1.0 1 16

Index Scan using clinical_elements_gwid_index on clinical_elements (cost=0.29..1.27 rows=1 width=53) (actual time=0.009..0.010 rows=1 loops=16)

  • Index Cond: ((clinical_elements_gwid)::text = (plan_instruction.plan_instruction_gwid)::text)
6. 0.000 0.032 ↓ 0.0 0 16

Bitmap Heap Scan on patient_clinical_elements (cost=254.98..259.00 rows=1 width=31) (actual time=0.002..0.002 rows=0 loops=16)

  • Recheck Cond: ((patient_clinical_elements_encounterid = 336) AND ((patient_clinical_elements_gwid)::text = (clinical_element_template_mapping.clinical_element_template_mapping_gwid)::text))
7. 0.000 0.032 ↓ 0.0 0 16

BitmapAnd (cost=254.98..254.98 rows=1 width=0) (actual time=0.002..0.002 rows=0 loops=16)

8. 0.032 0.032 ↓ 0.0 0 16

Bitmap Index Scan on patient_clinical_elements_encounterid_index (cost=0.00..6.48 rows=273 width=0) (actual time=0.002..0.002 rows=0 loops=16)

  • Index Cond: (patient_clinical_elements_encounterid = 336)
9. 0.000 0.000 ↓ 0.0 0

Bitmap Index Scan on patient_clinical_elements_gwid_index (cost=0.00..248.18 rows=9,016 width=0) (never executed)

  • Index Cond: ((patient_clinical_elements_gwid)::text = (clinical_element_template_mapping.clinical_element_template_mapping_gwid)::text)
10. 0.080 0.080 ↑ 1.0 1 16

Seq Scan on cnm_settings (cost=0.00..1.59 rows=1 width=1) (actual time=0.003..0.005 rows=1 loops=16)

  • Filter: (cnm_settings_id = 9)
  • Rows Removed by Filter: 46