explain.depesz.com

PostgreSQL's explain analyze made readable

Result: hiQv

Settings
# exclusive inclusive rows x rows loops node
1. 0.038 186.004 ↓ 0.0 0 1

Sort (cost=130,439.12..130,439.13 rows=4 width=426) (actual time=186.004..186.004 rows=0 loops=1)

  • Sort Key: psfv.section_detail_id, psfv.section_id, psfv.field_display_order, psfv.option_display_order
  • Sort Method: quicksort Memory: 25kB
2. 0.001 185.966 ↓ 0.0 0 1

Subquery Scan on psfv (cost=1,001.27..130,439.08 rows=4 width=426) (actual time=185.966..185.966 rows=0 loops=1)

3. 0.001 185.965 ↓ 0.0 0 1

Append (cost=1,001.27..130,438.96 rows=4 width=620) (actual time=185.965..185.965 rows=0 loops=1)

4. 0.000 185.963 ↓ 0.0 0 1

Subquery Scan on *SELECT* 1 (cost=1,001.27..130,438.96 rows=3 width=262) (actual time=185.963..185.963 rows=0 loops=1)

5. 21.068 200.354 ↓ 0.0 0 1

Gather (cost=1,001.27..130,438.86 rows=3 width=206) (actual time=185.963..200.354 rows=0 loops=1)

  • Workers Planned: 2
  • Workers Launched: 2
6. 0.001 179.286 ↓ 0.0 0 3

Nested Loop Left Join (cost=1.27..129,438.56 rows=1 width=206) (actual time=179.286..179.286 rows=0 loops=3)

7. 0.001 179.285 ↓ 0.0 0 3

Nested Loop (cost=0.99..129,434.24 rows=1 width=111) (actual time=179.285..179.285 rows=0 loops=3)

8. 0.000 179.284 ↓ 0.0 0 3

Nested Loop (cost=0.71..129,429.91 rows=1 width=77) (actual time=179.284..179.284 rows=0 loops=3)

9. 0.001 179.284 ↓ 0.0 0 3

Nested Loop (cost=0.43..129,429.60 rows=1 width=43) (actual time=179.284..179.284 rows=0 loops=3)

10. 179.283 179.283 ↓ 0.0 0 3

Parallel Seq Scan on patient_dynamic_section_values v (cost=0.00..129,420.66 rows=2 width=37) (actual time=179.283..179.283 rows=0 loops=3)

  • Filter: (prescription_id = 22135775)
  • Rows Removed by Filter: 1807676
11. 0.000 0.000 ↓ 0.0 0

Index Scan using patient_dynamic_section_details_pkey on patient_dynamic_section_details psd (cost=0.43..4.47 rows=1 width=10) (never executed)

  • Index Cond: (section_detail_id = v.section_detail_id)
  • Filter: (visit_type = 'o'::text)
12. 0.000 0.000 ↓ 0.0 0

Index Scan using physician_form_desc_pkey on section_master sm (cost=0.28..0.32 rows=1 width=38) (never executed)

  • Index Cond: (section_id = psd.section_id)
13. 0.000 0.000 ↓ 0.0 0

Index Scan using sfd_field_id_idx on section_field_desc sfd (cost=0.28..4.32 rows=1 width=38) (never executed)

  • Index Cond: (field_id = v.field_id)
14. 0.000 0.000 ↓ 0.0 0

Index Scan using sfo_option_id_idx on section_field_options o (cost=0.29..4.32 rows=1 width=23) (never executed)

  • Index Cond: (v.option_id = option_id)
15. 0.001 0.001 ↓ 0.0 0 1

Result (cost=0.00..0.00 rows=0 width=187) (actual time=0.001..0.001 rows=0 loops=1)

  • One-Time Filter: false
Planning time : 5.204 ms
Execution time : 200.611 ms