explain.depesz.com

PostgreSQL's explain analyze made readable

Result: L7Vs

Settings
# exclusive inclusive rows x rows loops node
1. 0.000 0.000 ↓ 0.0

Unique (cost=38,911.41..38,911.60 rows=13 width=53) (actual rows= loops=)

2. 0.000 0.000 ↓ 0.0

Sort (cost=38,911.41..38,911.44 rows=13 width=53) (actual rows= loops=)

  • Sort Key: conversations.updated_at DESC, conversations.id, conversations.created_at, conversations.wp_thread_id, conversations.deleted_by
3. 0.000 0.000 ↓ 0.0

Gather (cost=8,883.07..38,911.17 rows=13 width=53) (actual rows= loops=)

  • Workers Planned: 2
4. 0.000 0.000 ↓ 0.0

Nested Loop (cost=7,883.07..37,909.87 rows=5 width=53) (actual rows= loops=)

5. 0.000 0.000 ↓ 0.0

Hash Join (cost=7,882.65..37,907.04 rows=6 width=32) (actual rows= loops=)

  • Hash Cond: (personal_messages.conversation_id = conversation_participants.conversation_id)
  • Join Filter: (('f9b88e86-cf13-4a15-a9af-0c77ed925801'::text = ANY ((personal_messages.unread_by)::text[])) OR ((conversation_participants.user_id = 'f9b88e86-cf13-4a15-a9af-0c77ed925801'::uuid) AND (conversation_participants.wp_unread_count > 0)))
6. 0.000 0.000 ↓ 0.0

Parallel Seq Scan on personal_messages (cost=0.00..19,067.61 rows=113,261 width=29) (actual rows= loops=)

7. 0.000 0.000 ↓ 0.0

Hash (cost=3,827.29..3,827.29 rows=199,629 width=36) (actual rows= loops=)

8. 0.000 0.000 ↓ 0.0

Seq Scan on conversation_participants (cost=0.00..3,827.29 rows=199,629 width=36) (actual rows= loops=)

9. 0.000 0.000 ↓ 0.0

Index Scan using conversations_pkey on conversations (cost=0.42..0.47 rows=1 width=53) (actual rows= loops=)

  • Index Cond: (id = conversation_participants.conversation_id)