explain.depesz.com

PostgreSQL's explain analyze made readable

Result: JjLRt

Settings
# exclusive inclusive rows x rows loops node
1. 0.000 632.893 ↑ 125.7 40 1

Finalize HashAggregate (cost=16,577.35..16,627.63 rows=5,028 width=28) (actual time=632.861..632.893 rows=40 loops=1)

  • Group Key: email_history.object_id
2. 60.482 632.954 ↑ 74.0 40 1

Gather (cost=16,222.39..16,547.77 rows=2,958 width=28) (actual time=632.786..632.954 rows=40 loops=1)

  • Workers Planned: 1
  • Workers Launched: 1
3. 36.793 572.472 ↑ 147.9 20 2 / 2

Partial HashAggregate (cost=15,222.39..15,251.97 rows=2,958 width=28) (actual time=572.451..572.472 rows=20 loops=2)

  • Group Key: email_history.object_id
4. 62.163 535.679 ↓ 58.1 171,918 2 / 2

Nested Loop (cost=0.56..15,192.81 rows=2,958 width=6) (actual time=0.741..535.679 rows=171,918 loops=2)

5. 4.795 4.795 ↑ 1.3 22 2 / 2

Parallel Seq Scan on hub_auto_messages (cost=0.00..1,526.25 rows=28 width=4) (actual time=0.602..4.795 rows=22 loops=2)

  • Filter: ((hub_id = 39) OR is_default)
  • Rows Removed by Filter: 3672
6. 468.721 468.721 ↓ 51.9 7,996 43 / 2

Index Scan using email_history_object_id_idx on email_history (cost=0.56..486.55 rows=154 width=6) (actual time=0.040..21.801 rows=7,996 loops=43)

  • Index Cond: ((object_type = 'HubAutoMessage'::text) AND (object_id = hub_auto_messages.id))
Planning time : 1.619 ms
Execution time : 633.451 ms