explain.depesz.com

PostgreSQL's explain analyze made readable

Result: QRkm

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

Bitmap Heap Scan on patients (cost=32,360.83..32,361.96 rows=1 width=8) (actual time=181.363..181.363 rows=0 loops=1)

  • Recheck Cond: ((birth_date = '1965-05-02'::date) AND ((last_name)::text = 'MILLS'::text))
  • Filter: ((NOT has_deleted) AND is_active AND (NOT (hashed SubPlan 1)) AND ((first_name)::text = 'KIM'::text) AND ((gender)::text = 'F'::text) AND (company_id = 1))
  • Rows Removed by Filter: 1
  • Heap Blocks: exact=4
2. 0.004 1.052 ↓ 0.0 0 1

BitmapAnd (cost=3.44..3.44 rows=1 width=0) (actual time=1.052..1.052 rows=0 loops=1)

3. 0.531 0.531 ↓ 1.4 10 1

Bitmap Index Scan on patients_birth_date_idx (cost=0.00..1.57 rows=7 width=0) (actual time=0.531..0.531 rows=10 loops=1)

  • Index Cond: (birth_date = '1965-05-02'::date)
4. 0.517 0.517 ↓ 8.2 106 1

Bitmap Index Scan on patients_last_name_idx (cost=0.00..1.62 rows=13 width=0) (actual time=0.517..0.517 rows=106 loops=1)

  • Index Cond: ((last_name)::text = 'MILLS'::text)
5.          

SubPlan (for Bitmap Heap Scan)

6. 131.761 178.489 ↓ 6.3 5,142 1

Gather (cost=1,000.00..32,355.35 rows=817 width=8) (actual time=3.420..178.489 rows=5,142 loops=1)

  • Workers Planned: 4
  • Workers Launched: 4
7. 46.728 46.728 ↓ 5.0 1,028 5 / 5

Parallel Seq Scan on patients patients_1 (cost=0.00..31,273.65 rows=204 width=8) (actual time=0.527..46.728 rows=1,028 loops=5)

  • Filter: ((NOT has_deleted) AND ((id = 156,449) OR ((patient_info -> 'showExistPatient'::text) = 'true'::text)))
  • Rows Removed by Filter: 31,600
Planning time : 4.213 ms
Execution time : 193.907 ms