explain.depesz.com

PostgreSQL's explain analyze made readable

Result: Bryp

Settings
# exclusive inclusive rows x rows loops node
1. 3.120 11,046.138 ↓ 1,534.0 1,534 1

Sort (cost=5.03..5.04 rows=1 width=537) (actual time=11,045.982..11,046.138 rows=1,534 loops=1)

  • Sort Key: appointments.created_at DESC
  • Sort Method: quicksort Memory: 456kB
2. 1.855 11,043.018 ↓ 1,534.0 1,534 1

Nested Loop (cost=1.22..5.02 rows=1 width=537) (actual time=10,318.678..11,043.018 rows=1,534 loops=1)

3. 2.430 11,024.363 ↓ 1,680.0 1,680 1

Nested Loop (cost=0.80..4.32 rows=1 width=541) (actual time=10,318.658..11,024.363 rows=1,680 loops=1)

4. 11,006.813 11,006.813 ↓ 1,680.0 1,680 1

Index Scan using appointments_updated_at_idx on appointments (cost=0.38..1.68 rows=1 width=537) (actual time=10,318.633..11,006.813 rows=1,680 loops=1)

  • Filter: ((source)::text = 'patient'::text)
  • Rows Removed by Filter: 1,271
5. 15.120 15.120 ↑ 1.0 1 1,680

Index Scan using agendas_pkey on agendas (cost=0.42..2.64 rows=1 width=8) (actual time=0.009..0.009 rows=1 loops=1,680)

  • Index Cond: (id = appointments.agenda_id)
6. 16.800 16.800 ↑ 1.0 1 1,680

Index Scan using organizations_pkey on organizations (cost=0.42..0.71 rows=1 width=4) (actual time=0.010..0.010 rows=1 loops=1,680)

  • Index Cond: (id = agendas.organization_id)
  • Filter: ((country)::text = 'fr'::text)
  • Rows Removed by Filter: 0
Planning time : 1.340 ms
Execution time : 11,046.386 ms