explain.depesz.com

PostgreSQL's explain analyze made readable

Result: WBuX

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

cm_1 (cost=6.86..9.88 rows=1 width=2) (never executed)

  • Recheck Cond: ((((md_1.code_type)::text = (code_type)::text) AND ((md_1.icd_code)::text = (code)::text)) OR (((md_1.code_type)::text = (code_type)::text) AND ((md_1.changed_icd_code)::text = (code)::text)))
2. 0.000 0.000 ↓ 0.0 0

BitmapOr (cost=6.86..6.86 rows=1 width=0) (never executed)

3. 0.000 0.000 ↓ 0.0 0

Bitmap Index Scan on pkey (cost=0.00..3.43 rows=1 width=0) (never executed)

  • Index Cond: (((md_1.code_type)::text = (code_type)::text) AND ((md_1.icd_code)::text = (code)::text))
4. 0.000 0.000 ↓ 0.0 0

Bitmap Index Scan on pkey (cost=0.00..3.43 rows=1 width=0) (never executed)

  • Index Cond: (((md_1.code_type)::text = (code_type)::text) AND ((md_1.changed_icd_code)::text = (code)::text))
5. 0.000 0.000 ↓ 0.0 0

Hash (cost=1.16..1.16 rows=12 width=4) (never executed)

6. 0.000 0.000 ↓ 0.0 0

Seq Scan on special_reporting sr1_1 (cost=0.00..1.16 rows=12 width=4) (never executed)

  • Filter: ((type)::text = 'S'::text)
7. 0.000 0.000 ↓ 0.0 0

Materialize (cost=0.00..1.25 rows=17 width=4) (never executed)

8. 0.000 0.000 ↓ 0.0 0

Seq Scan on code_group cg_1 (cost=0.00..1.17 rows=17 width=4) (never executed)

9. 0.000 0.000 ↓ 0.0 0

Index Scan using doctors_pkey on doctors doc_1 (cost=0.28..0.46 rows=1 width=39) (never executed)

  • Index Cond: ((doctor_id)::text = (pr_1.doctor)::text)
10. 0.000 0.000 ↓ 0.0 0

Index Scan using patient_details_pkey on patient_details pd_1 (cost=0.43..6.23 rows=1 width=99) (never executed)

  • Index Cond: ((mr_no)::text = (pr_1.mr_no)::text)
11. 0.000 0.000 ↓ 0.0 0

Materialize (cost=0.00..1.31 rows=21 width=14) (never executed)

12. 0.000 0.000 ↓ 0.0 0

Seq Scan on salutation_master s_1 (cost=0.00..1.21 rows=21 width=14) (never executed)

13. 0.000 0.000 ↓ 0.0 0

Materialize (cost=0.00..1.90 rows=60 width=23) (never executed)

14. 0.000 0.000 ↓ 0.0 0

Seq Scan on department dept_1 (cost=0.00..1.60 rows=60 width=23) (never executed)

15. 0.000 0.000 ↓ 0.0 0

Index Scan using diagnostics_pkey on diagnostics diag (cost=0.28..0.30 rows=1 width=81) (never executed)

  • Index Cond: ((test_id)::text = (tp.test_id)::text)
16. 0.000 0.000 ↓ 0.0 0

Materialize (cost=0.00..822.96 rows=1 width=26) (never executed)

17. 0.000 0.000 ↓ 0.0 0

Seq Scan on patient_special_reporting psr_1 (cost=0.00..822.95 rows=1 width=26) (never executed)