explain.depesz.com

PostgreSQL's explain analyze made readable

Result: 78gI

Settings
# exclusive inclusive rows x rows loops node
1. 0.000 22.763 ↓ 1.3 2,628 1

Gather (cost=1,064.94..92,298.18 rows=1,956 width=845) (actual time=1.360..22.763 rows=2,628 loops=1)

  • Workers Planned: 1
  • Workers Launched: 1
2. 0.750 8.190 ↓ 1.1 1,314 2

Nested Loop Left Join (cost=64.94..10,943.53 rows=1,151 width=807) (actual time=0.444..8.190 rows=1,314 loops=2)

3. 4.640 7.440 ↓ 1.1 1,314 2

Nested Loop Left Join (cost=64.65..10,552.00 rows=1,151 width=807) (actual time=0.439..7.440 rows=1,314 loops=2)

4. 0.819 2.797 ↓ 1.1 1,314 2

Hash Join (cost=64.23..4,528.82 rows=1,151 width=799) (actual time=0.422..2.797 rows=1,314 loops=2)

  • Hash Cond: (staffing_mission.type_id = staffing_typemission.id)
5. 1.499 1.969 ↓ 1.1 1,314 2

Parallel Bitmap Heap Scan on staffing_mission (cost=63.14..4,521.50 rows=1,151 width=737) (actual time=0.372..1.969 rows=1,314 loops=2)

  • Recheck Cond: (agent_id = ANY ('{1059,932,1093,1190,1066,1051,468,1046,987,638}'::integer[]))
  • Filter: ((status)::text <> 'CANCELLED'::text)
  • Rows Removed by Filter: 38
  • Heap Blocks: exact=150
6. 0.470 0.470 ↓ 1.1 2,705 1

Bitmap Index Scan on staffing_mission_2f7f0f6b (cost=0.00..62.65 rows=2,461 width=0) (actual time=0.470..0.470 rows=2,705 loops=1)

  • Index Cond: (agent_id = ANY ('{1059,932,1093,1190,1066,1051,468,1046,987,638}'::integer[]))
7. 0.003 0.009 ↑ 1.0 4 2

Hash (cost=1.04..1.04 rows=4 width=62) (actual time=0.009..0.009 rows=4 loops=2)

  • Buckets: 1024 Batches: 1 Memory Usage: 9kB
8. 0.006 0.006 ↑ 1.0 4 2

Seq Scan on staffing_typemission (cost=0.00..1.04 rows=4 width=62) (actual time=0.005..0.006 rows=4 loops=2)

9. 0.003 0.003 ↑ 1.0 1 2,628

Index Scan using staffing_reservation_pkey on staffing_reservation (cost=0.42..5.23 rows=1 width=12) (actual time=0.003..0.003 rows=1 loops=2,628)

  • Index Cond: (staffing_mission.reservation_id = id)
10. 0.000 0.000 ↓ 0.0 0 2,628

Index Scan using stripe_bnblord_charge_pkey on stripe_bnblord_charge (cost=0.29..0.34 rows=1 width=8) (actual time=0.000..0.000 rows=0 loops=2,628)

  • Index Cond: (staffing_reservation.extra_checkin_charge_deprecated_id = id)
11.          

SubPlan (for Gather)

12. 2.628 18.396 ↓ 0.0 0 2,628

Limit (cost=20.48..20.49 rows=1 width=8) (actual time=0.007..0.007 rows=0 loops=2,628)

13. 0.000 15.768 ↓ 0.0 0 2,628

Unique (cost=20.48..20.94 rows=91 width=8) (actual time=0.006..0.006 rows=0 loops=2,628)

14. 0.000 15.768 ↓ 0.0 0 2,628

Sort (cost=20.48..20.71 rows=91 width=8) (actual time=0.006..0.006 rows=0 loops=2,628)

  • Sort Key: u0.id DESC
  • Sort Method: quicksort Memory: 25kB
15. 2.616 15.768 ↓ 0.0 0 2,628

Nested Loop (cost=1.41..17.52 rows=91 width=8) (actual time=0.006..0.006 rows=0 loops=2,628)

16. 0.000 13.140 ↓ 0.0 0 2,628

Nested Loop (cost=1.13..17.23 rows=1 width=16) (actual time=0.005..0.005 rows=0 loops=2,628)

17. 2.628 13.140 ↑ 1.0 1 2,628

Nested Loop (cost=0.84..16.88 rows=1 width=4) (actual time=0.005..0.005 rows=1 loops=2,628)

18. 5.256 5.256 ↑ 1.0 1 2,628

Index Scan using staffing_mission_pkey on staffing_mission u3 (cost=0.42..8.44 rows=1 width=4) (actual time=0.002..0.002 rows=1 loops=2,628)

  • Index Cond: (id = staffing_mission.id)
19. 5.256 5.256 ↑ 1.0 1 2,628

Index Scan using staffing_reservation_pkey on staffing_reservation u2 (cost=0.42..8.44 rows=1 width=8) (actual time=0.002..0.002 rows=1 loops=2,628)

  • Index Cond: (id = u3.reservation_id)
20. 0.000 0.000 ↓ 0.0 0 2,495

Index Scan using stripe_bnblord_charge_payment_intent_id_c54280a4 on stripe_bnblord_charge u0 (cost=0.29..0.34 rows=1 width=12) (actual time=0.000..0.000 rows=0 loops=2,495)

  • Index Cond: (payment_intent_id = u2.extra_checkin_payment_intent_id)
21. 0.012 0.012 ↑ 1.0 1 4

Index Only Scan using stripe_bnblord_paymentintent_pkey on stripe_bnblord_paymentintent u1 (cost=0.28..0.29 rows=1 width=4) (actual time=0.003..0.003 rows=1 loops=4)

  • Index Cond: (id = u0.payment_intent_id)
  • Heap Fetches: 4
22. 0.000 0.136 ↓ 0.0 0 17

Limit (cost=20.48..20.49 rows=1 width=8) (actual time=0.008..0.008 rows=0 loops=17)

23. 0.017 0.136 ↓ 0.0 0 17

Unique (cost=20.48..20.94 rows=91 width=8) (actual time=0.008..0.008 rows=0 loops=17)

24. 0.000 0.119 ↓ 0.0 0 17

Sort (cost=20.48..20.71 rows=91 width=8) (actual time=0.007..0.007 rows=0 loops=17)

  • Sort Key: u0_1.id DESC
  • Sort Method: quicksort Memory: 25kB
25. 0.009 0.119 ↓ 0.0 0 17

Nested Loop (cost=1.41..17.52 rows=91 width=8) (actual time=0.007..0.007 rows=0 loops=17)

26. 0.017 0.102 ↓ 0.0 0 17

Nested Loop (cost=1.13..17.23 rows=1 width=16) (actual time=0.006..0.006 rows=0 loops=17)

27. 0.000 0.068 ↑ 1.0 1 17

Nested Loop (cost=0.84..16.88 rows=1 width=4) (actual time=0.004..0.004 rows=1 loops=17)

28. 0.034 0.034 ↑ 1.0 1 17

Index Scan using staffing_mission_pkey on staffing_mission u3_1 (cost=0.42..8.44 rows=1 width=4) (actual time=0.002..0.002 rows=1 loops=17)

  • Index Cond: (id = staffing_mission.id)
29. 0.034 0.034 ↑ 1.0 1 17

Index Scan using staffing_reservation_pkey on staffing_reservation u2_1 (cost=0.42..8.44 rows=1 width=8) (actual time=0.002..0.002 rows=1 loops=17)

  • Index Cond: (id = u3_1.reservation_id)
30. 0.017 0.017 ↓ 0.0 0 17

Index Scan using stripe_bnblord_charge_payment_intent_id_c54280a4 on stripe_bnblord_charge u0_1 (cost=0.29..0.34 rows=1 width=12) (actual time=0.001..0.001 rows=0 loops=17)

  • Index Cond: (payment_intent_id = u2_1.extra_checkin_payment_intent_id)
31. 0.008 0.008 ↑ 1.0 1 4

Index Only Scan using stripe_bnblord_paymentintent_pkey on stripe_bnblord_paymentintent u1_1 (cost=0.28..0.29 rows=1 width=4) (actual time=0.002..0.002 rows=1 loops=4)

  • Index Cond: (id = u0_1.payment_intent_id)
  • Heap Fetches: 4
Planning time : 1.694 ms
Execution time : 22.988 ms