explain.depesz.com

PostgreSQL's explain analyze made readable

Result: tN2V

Settings
# exclusive inclusive rows x rows loops node
1. 0.025 562,849.941 ↓ 0.0 0 1

Limit (cost=0.86..1,500.33 rows=1 width=462) (actual time=562,849.941..562,849.941 rows=0 loops=1)

  • Buffers: shared hit=5672956 read=1426480
2. 226,062.554 562,849.916 ↓ 0.0 0 1

Nested Loop (cost=0.86..55,295,868.85 rows=36,877 width=462) (actual time=562,849.916..562,849.916 rows=0 loops=1)

  • Buffers: shared hit=5672956 read=1426480
3. 199,151.694 199,151.694 ↑ 1.0 15,292,852 1

Index Scan Backward using audit_event_date on audit_event (cost=0.43..1,286,508.29 rows=15,336,281 width=58) (actual time=0.038..199,151.694 rows=15,292,852 loops=1)

  • Filter: (((tenant_name)::text = 'juyi'::text) AND ((realm_name)::text = 'evolve'::text))
  • Rows Removed by Filter: 777469
  • Buffers: shared hit=1343056 read=832264
4. 137,635.668 137,635.668 ↓ 0.0 0 15,292,852

Index Scan using patient_details_pkey on patient_details (cost=0.42..3.51 rows=1 width=441) (actual time=0.009..0.009 rows=0 loops=15,292,852)

  • Index Cond: ((id)::text = (audit_event.patient_details_id)::text)
  • Filter: ((deprecation_date_time IS NULL) AND (((birth_date IS NULL) AND ('9990240957'::text = (business_identifier)::text)) OR ((patient_id)::text = 'c806749d-4b81-42b0-9111-32246d1c4d72'::text)))
  • Rows Removed by Filter: 0
  • Buffers: shared hit=4329900 read=594216