explain.depesz.com

PostgreSQL's explain analyze made readable

Result: lJYr : Optimization for: Optimization for: Optimization for: plan #T8Up; plan #Lsjq; plan #4WJ3

Settings

Optimization path:

# exclusive inclusive rows x rows loops node
1. 0.004 0.023 ↑ 1.0 1 1

Aggregate (cost=89.37..89.38 rows=1 width=8) (actual time=0.023..0.023 rows=1 loops=1)

2.          

CTE callentries

3. 0.000 0.017 ↓ 0.0 0 1

Bitmap Heap Scan on c4_call_entry (cost=72.86..76.88 rows=1 width=32) (actual time=0.017..0.017 rows=0 loops=1)

  • Recheck Cond: ((from_user_id = 'ca5870fb-9978-403a-94a9-2993d0c7e582'::uuid) AND (account_id = 'ca5870fb-9978-403a-94a9-2993d0c7e582'::uuid))
4. 0.000 0.017 ↓ 0.0 0 1

BitmapAnd (cost=72.86..72.86 rows=1 width=0) (actual time=0.017..0.017 rows=0 loops=1)

5. 0.017 0.017 ↓ 0.0 0 1

Bitmap Index Scan on call_entry_from_user_id_index (cost=0.00..11.41 rows=398 width=0) (actual time=0.017..0.017 rows=0 loops=1)

  • Index Cond: (from_user_id = 'ca5870fb-9978-403a-94a9-2993d0c7e582'::uuid)
6. 0.000 0.000 ↓ 0.0 0

Bitmap Index Scan on call_entry_account_id_index (cost=0.00..61.20 rows=2,236 width=0) (never executed)

  • Index Cond: (account_id = 'ca5870fb-9978-403a-94a9-2993d0c7e582'::uuid)
7. 0.019 0.019 ↓ 0.0 0 1

CTE Scan on callentries (cost=0.00..12.49 rows=1 width=16) (actual time=0.019..0.019 rows=0 loops=1)

  • Filter: ((from_user_id = 'ca5870fb-9978-403a-94a9-2993d0c7e582'::uuid) OR (alternatives: SubPlan 2 or hashed SubPlan 3))
8.          

SubPlan (for CTE Scan)

9. 0.000 0.000 ↓ 0.0 0

Index Scan using call_entry_targets_call_entry_id_index on c4_call_entry_targets (cost=0.42..12.46 rows=1 width=0) (never executed)

  • Index Cond: (call_entry_id = callentries.id)
  • Filter: (user_id = 'ca5870fb-9978-403a-94a9-2993d0c7e582'::uuid)
10. 0.000 0.000 ↓ 0.0 0

Bitmap Heap Scan on c4_call_entry_targets c4_call_entry_targets_1 (cost=15.96..1,572.40 rows=456 width=16) (never executed)

  • Recheck Cond: (user_id = 'ca5870fb-9978-403a-94a9-2993d0c7e582'::uuid)
11. 0.000 0.000 ↓ 0.0 0

Bitmap Index Scan on call_entry_targets_user_id_index (cost=0.00..15.85 rows=456 width=0) (never executed)

  • Index Cond: (user_id = 'ca5870fb-9978-403a-94a9-2993d0c7e582'::uuid)
Planning time : 0.852 ms
Execution time : 0.127 ms