explain.depesz.com

PostgreSQL's explain analyze made readable

Result: pM7p

Settings
# exclusive inclusive rows x rows loops node
1. 0.045 32.027 ↑ 1.0 1 1

Aggregate (cost=14,781.60..14,781.61 rows=1 width=8) (actual time=27.797..32.027 rows=1 loops=1)

  • Buffers: shared hit=4,974
2. 6.968 31.982 ↑ 62.0 32 1

Gather (cost=1,000.09..14,780.61 rows=1,984 width=17) (actual time=3.720..31.982 rows=32 loops=1)

  • Workers Planned: 1
  • Workers Launched: 1
  • Buffers: shared hit=4,974
3. 0.017 25.014 ↑ 72.9 16 2 / 2

Nested Loop (cost=0.08..13,582.21 rows=1,167 width=17) (actual time=9.297..25.014 rows=16 loops=2)

  • Buffers: shared hit=4,974
4. 24.709 24.709 ↑ 154.2 16 2 / 2

Parallel Seq Scan on conversation convo (cost=0.00..5,263.90 rows=2,467 width=65) (actual time=9.244..24.709 rows=16 loops=2)

  • Filter: ((NOT "isArchived") AND ("lastReceivedMessageSentAt" IS NOT NULL) AND ("shopId" = 'shopify-23182543'::text))
  • Rows Removed by Filter: 102,026
  • Buffers: shared hit=4,845
5. 0.288 0.288 ↑ 1.0 1 32 / 2

Index Scan using "PK_ba01f0a3e0123651915008bc578" on message lm (cost=0.08..3.37 rows=1 width=17) (actual time=0.018..0.018 rows=1 loops=32)

  • Index Cond: (id = convo."lastMessageId")
  • Filter: ("shopId" = 'shopify-23182543'::text)
  • Buffers: shared hit=129
Planning time : 0.507 ms
Execution time : 32.073 ms