explain.depesz.com

PostgreSQL's explain analyze made readable

Result: 5X5w

Settings
# exclusive inclusive rows x rows loops node
1. 0.065 1.966 ↓ 17.0 17 1

Unique (cost=16.27..16.48 rows=1 width=2,443) (actual time=1.898..1.966 rows=17 loops=1)

2. 0.468 1.901 ↓ 38.0 38 1

Sort (cost=16.27..16.27 rows=1 width=2,443) (actual time=1.898..1.901 rows=38 loops=1)

  • Sort Key: users.id, users.email, users.encrypted_password, users.reset_password_token, users.reset_password_sent_at, users.remember_created_at, users.sign_in_count, users.current_sign_in_at, users.last_sign_in_at, users.current_sign_in_ip, users.last_sign_in_ip, users.created_at, users.updated_at, users.name, users.admin, users.projects_limit, users.skype, users.linkedin, users.twitter, users.bio, users.failed_attempts, users.locked_at, users.username, users.can_create_group, users.can_create_team, users.state, users.color_scheme_id, users.password_expires_at, users.created_by_id, users.last_credential_check_at, users.avatar, users.confirmation_token, users.confirmed_at, users.confirmation_sent_at, users.unconfirmed_email, users.hide_no_ssh_key, users.website_url, users.admin_email_unsubscribed_at, users.notification_email, users.hide_no_password, users.password_automatically_set, users.location, users.encrypted_otp_secret, users.encrypted_otp_secret_iv, users.encrypted_otp_secret_salt, users.otp_required_for_login, users.otp_backup_codes, users.public_email, users.dashboard, users.project_view, users.consumed_timestep, users.layout, users.hide_project_limit, users.note, users.unlock_token, users.otp_grace_period_started_at, users.external, users.incoming_email_token, users.organization, users.auditor, users.require_two_factor_authentication_from_group, users.two_factor_grace_period, users.ghost, users.last_activity_on, users.notified_of_own_activity, users.preferred_language, users.email_opted_in, users.email_opted_in_ip, users.email_opted_in_source_id, users.email_opted_in_at, users.theme_id, users.accepted_term_id, users.feed_token, users.private_profile, users.roadmap_layout, users.include_private_contributions, users.commit_email, users.group_view, users.managing_group_id, users.bot_type, users.first_name, users.last_name, users.static_object_token, users.role
  • Sort Method: quicksort Memory: 44kB
3. 0.054 1.433 ↓ 38.0 38 1

Nested Loop (cost=12.12..16.26 rows=1 width=2,443) (actual time=1.313..1.433 rows=38 loops=1)

4. 0.005 1.341 ↓ 38.0 38 1

Nested Loop (cost=11.84..13.96 rows=1 width=4) (actual time=1.302..1.341 rows=38 loops=1)

5. 0.021 1.292 ↓ 11.0 11 1

HashAggregate (cost=11.56..11.57 rows=1 width=8) (actual time=1.289..1.292 rows=11 loops=1)

  • Group Key: namespaces.id
6. 0.414 1.271 ↓ 58.0 58 1

Hash Join (cost=3.95..11.56 rows=1 width=8) (actual time=1.172..1.271 rows=58 loops=1)

  • Hash Cond: (issue_user_mentions.mentioned_group_id = namespaces.id)
7. 0.834 0.834 ↓ 21.5 4,929 1

Index Scan using index_issue_user_mentions_on_issue_id on issue_user_mentions (cost=0.43..7.44 rows=229 width=4) (actual time=0.007..0.834 rows=4,929 loops=1)

  • Index Cond: (issue_id = 3937)
8. 0.009 0.023 ↑ 1.1 12 1

Hash (cost=3.35..3.35 rows=13 width=4) (actual time=0.023..0.023 rows=12 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 9kB
9. 0.014 0.014 ↑ 1.1 12 1

Index Scan using index_namespaces_on_type_partial on namespaces (cost=0.14..3.35 rows=13 width=4) (actual time=0.009..0.014 rows=12 loops=1)

  • Index Cond: ((type)::text = 'Group'::text)
10. 0.044 0.044 ↓ 3.0 3 11

Index Scan using index_members_on_source_id_and_source_type on members (cost=0.28..2.38 rows=1 width=8) (actual time=0.003..0.004 rows=3 loops=11)

  • Index Cond: ((source_id = namespaces.id) AND ((source_type)::text = 'Namespace'::text))
  • Filter: ((requested_at IS NULL) AND ((type)::text = 'GroupMember'::text))
11. 0.038 0.038 ↑ 1.0 1 38

Index Scan using users_pkey on users (cost=0.28..2.30 rows=1 width=2,443) (actual time=0.001..0.001 rows=1 loops=38)

  • Index Cond: (id = members.user_id)
Planning time : 3.161 ms
Execution time : 2.224 ms