explain.depesz.com

PostgreSQL's explain analyze made readable

Result: MnXv

Settings
# exclusive inclusive rows x rows loops node
1. 2.488 153.324 ↑ 1.0 4 1

Hash Join (cost=40,879.32..44,152.40 rows=4 width=2,019) (actual time=146.198..153.324 rows=4 loops=1)

  • Hash Cond: ((cs_usr_users.usr_username)::text = (usr.usr_username)::text)
2. 3.276 150.807 ↑ 5.7 21,806 1

Unique (cost=40,872.01..42,430.59 rows=124,687 width=214) (actual time=145.429..150.807 rows=21,806 loops=1)

3. 105.667 147.531 ↑ 5.7 21,874 1

Sort (cost=40,872.01..41,183.72 rows=124,687 width=214) (actual time=145.424..147.531 rows=21,874 loops=1)

  • Sort Key: cs_rle_roles.rle_name, cs_rle_roles.rle_tap_code, cs_ure_user_roles.ure_include_yn, cs_usr_users.usr_username
  • Sort Method: quicksort Memory: 3793kB
4. 1.249 41.864 ↑ 5.7 21,874 1

Append (cost=11.19..18,446.28 rows=124,687 width=214) (actual time=19.047..41.864 rows=21,874 loops=1)

5. 0.004 0.035 ↓ 0.0 0 1

Nested Loop (cost=11.19..306.50 rows=40 width=62) (actual time=0.035..0.035 rows=0 loops=1)

6. 0.019 0.031 ↓ 0.0 0 1

Hash Join (cost=10.90..24.40 rows=40 width=51) (actual time=0.031..0.031 rows=0 loops=1)

  • Hash Cond: (cs_rle_roles.rle_id = cs_ure_user_roles.ure_rle_id)
7. 0.009 0.009 ↑ 314.0 1 1

Seq Scan on cs_rle_roles (cost=0.00..11.93 rows=314 width=43) (actual time=0.009..0.009 rows=1 loops=1)

  • Filter: ((rle_status)::text = 'active'::text)
8. 0.001 0.003 ↓ 0.0 0 1

Hash (cost=10.40..10.40 rows=40 width=24) (actual time=0.003..0.003 rows=0 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 8kB
9. 0.002 0.002 ↓ 0.0 0 1

Seq Scan on cs_ure_user_roles (cost=0.00..10.40 rows=40 width=24) (actual time=0.002..0.002 rows=0 loops=1)

10. 0.000 0.000 ↓ 0.0 0

Index Scan using cs_usr_pk on cs_usr_users (cost=0.29..7.04 rows=1 width=27) (never executed)

  • Index Cond: (usr_id = cs_ure_user_roles.ure_usr_id)
11. 4.349 30.498 ↑ 5.7 21,775 1

Hash Join (cost=7,549.40..9,692.19 rows=124,548 width=86) (actual time=19.012..30.498 rows=21,775 loops=1)

  • Hash Cond: (cs_ugp_user_groups.ugp_grp_id = cs_grp_groups.grp_id)
12. 5.743 25.279 ↓ 1.0 16,249 1

Hash Join (cost=7,480.48..8,178.03 rows=15,981 width=27) (actual time=18.122..25.279 rows=16,249 loops=1)

  • Hash Cond: (cs_ugp_user_groups.ugp_usr_id = cs_usr_users_1.usr_id)
13. 1.592 1.592 ↓ 1.0 16,249 1

Seq Scan on cs_ugp_user_groups (cost=0.00..477.81 rows=15,981 width=16) (actual time=0.004..1.592 rows=16,249 loops=1)

14. 5.894 17.944 ↓ 1.0 27,979 1

Hash (cost=7,130.77..7,130.77 rows=27,977 width=27) (actual time=17.944..17.944 rows=27,979 loops=1)

  • Buckets: 32768 Batches: 1 Memory Usage: 1981kB
15. 12.050 12.050 ↓ 1.0 27,979 1

Seq Scan on cs_usr_users cs_usr_users_1 (cost=0.00..7,130.77 rows=27,977 width=27) (actual time=0.007..12.050 rows=27,979 loops=1)

16. 0.159 0.870 ↓ 1.0 719 1

Hash (cost=59.96..59.96 rows=717 width=51) (actual time=0.870..0.870 rows=719 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 69kB
17. 0.164 0.711 ↓ 1.0 719 1

Hash Join (cost=21.15..59.96 rows=717 width=51) (actual time=0.257..0.711 rows=719 loops=1)

  • Hash Cond: (cs_gre_group_roles.gre_grp_id = cs_grp_groups.grp_id)
18. 0.258 0.497 ↓ 1.0 719 1

Hash Join (cost=15.85..44.88 rows=717 width=43) (actual time=0.191..0.497 rows=719 loops=1)

  • Hash Cond: (cs_gre_group_roles.gre_rle_id = cs_rle_roles_1.rle_id)
19. 0.070 0.070 ↓ 1.0 719 1

Seq Scan on cs_gre_group_roles (cost=0.00..19.17 rows=717 width=16) (actual time=0.003..0.070 rows=719 loops=1)

20. 0.077 0.169 ↑ 1.0 314 1

Hash (cost=11.93..11.93 rows=314 width=43) (actual time=0.169..0.169 rows=314 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 33kB
21. 0.092 0.092 ↑ 1.0 314 1

Seq Scan on cs_rle_roles cs_rle_roles_1 (cost=0.00..11.93 rows=314 width=43) (actual time=0.004..0.092 rows=314 loops=1)

  • Filter: ((rle_status)::text = 'active'::text)
22. 0.019 0.050 ↑ 1.0 92 1

Hash (cost=4.15..4.15 rows=92 width=8) (actual time=0.050..0.050 rows=92 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 12kB
23. 0.031 0.031 ↑ 1.0 92 1

Seq Scan on cs_grp_groups (cost=0.00..4.15 rows=92 width=8) (actual time=0.004..0.031 rows=92 loops=1)

  • Filter: ((grp_status)::text = 'active'::text)
24. 10.082 10.082 ↑ 1.0 99 1

Seq Scan on cs_usr_users cs_usr_users_2 (cost=0.00..7,200.71 rows=99 width=115) (actual time=0.008..10.082 rows=99 loops=1)

  • Filter: (usr_internal_user_yn = 'Y'::bpchar)
  • Rows Removed by Filter: 27880
25. 0.015 0.029 ↑ 1.0 1 1

Hash (cost=7.30..7.30 rows=1 width=1,805) (actual time=0.029..0.029 rows=1 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 9kB
26. 0.014 0.014 ↑ 1.0 1 1

Index Scan using cs_usr_pk on cs_usr_users usr (cost=0.29..7.30 rows=1 width=1,805) (actual time=0.013..0.014 rows=1 loops=1)

  • Index Cond: (usr_id = 1)