explain.depesz.com

PostgreSQL's explain analyze made readable

Result: GGml

Settings
# exclusive inclusive rows x rows loops node
1. 0.000 2.262 ↑ 1.0 10 1

Limit (cost=28.64..1,495.33 rows=10 width=180) (actual time=1.070..2.262 rows=10 loops=1)

2. 0.379 2.262 ↑ 4,867.8 10 1

GroupAggregate (cost=28.64..7,139,567.11 rows=48,678 width=180) (actual time=1.070..2.262 rows=10 loops=1)

  • Group Key: clps.id
3. 0.001 1.883 ↑ 3,190.6 61 1

Nested Loop Left Join (cost=28.64..7,122,536.99 rows=194,625 width=73) (actual time=0.626..1.883 rows=61 loops=1)

4. 0.012 1.577 ↑ 3,190.6 61 1

Nested Loop Left Join (cost=18.90..4,441,480.30 rows=194,625 width=69) (actual time=0.614..1.577 rows=61 loops=1)

5. 0.022 1.199 ↑ 3,190.6 61 1

Nested Loop Left Join (cost=9.16..1,760,910.17 rows=194,625 width=73) (actual time=0.594..1.199 rows=61 loops=1)

6. 0.054 0.933 ↑ 3,190.6 61 1

Nested Loop (cost=0.84..136,277.99 rows=194,625 width=72) (actual time=0.585..0.933 rows=61 loops=1)

7. 0.000 0.818 ↑ 3,190.6 61 1

Nested Loop (cost=0.56..22,665.64 rows=194,625 width=48) (actual time=0.582..0.818 rows=61 loops=1)

8. 0.200 0.200 ↑ 70.8 688 1

Index Scan using claire_learning_path_subscription_pkey on claire_learning_path_subscription clps (cost=0.29..2,537.97 rows=48,678 width=40) (actual time=0.006..0.200 rows=688 loops=1)

9. 0.688 0.688 ↓ 0.0 0 688

Index Scan using idx_1afddd081dcbee98 on claire_learning_path_project clpp (cost=0.28..0.36 rows=5 width=8) (actual time=0.001..0.001 rows=0 loops=688)

  • Index Cond: (learning_path_id = clps.learning_path_id)
10. 0.061 0.061 ↑ 1.0 1 61

Index Scan using claire_project_pkey on claire_project cp (cost=0.28..0.57 rows=1 width=28) (actual time=0.001..0.001 rows=1 loops=61)

  • Index Cond: (id = clpp.project_id)
11. 0.061 0.244 ↓ 0.0 0 61

Limit (cost=8.32..8.33 rows=1 width=17) (actual time=0.004..0.004 rows=0 loops=61)

12. 0.061 0.183 ↓ 0.0 0 61

Sort (cost=8.32..8.33 rows=1 width=17) (actual time=0.003..0.003 rows=0 loops=61)

  • Sort Key: _cps.started_at DESC
  • Sort Method: quicksort Memory: 25kB
13. 0.122 0.122 ↓ 0.0 0 61

Index Scan using idx_claire_project_session_project_id_user_id on claire_project_session _cps (cost=0.29..8.31 rows=1 width=17) (actual time=0.002..0.002 rows=0 loops=61)

  • Index Cond: ((project_id = clpp.project_id) AND (user_id = clps.user_id))
14. 0.122 0.366 ↓ 0.0 0 61

Limit (cost=9.74..13.75 rows=1 width=20) (actual time=0.006..0.006 rows=0 loops=61)

15. 0.000 0.244 ↓ 0.0 0 61

Bitmap Heap Scan on claire_project_completion _cpc (cost=9.74..13.75 rows=1 width=20) (actual time=0.004..0.004 rows=0 loops=61)

  • Recheck Cond: ((user_id = clps.user_id) AND (project_id = clpp.project_id))
16. 0.045 0.244 ↓ 0.0 0 61

BitmapAnd (cost=9.74..9.74 rows=1 width=0) (actual time=0.004..0.004 rows=0 loops=61)

17. 0.061 0.061 ↑ 8.0 1 61

Bitmap Index Scan on idx_56ff5e38a76ed395 (cost=0.00..4.35 rows=8 width=0) (actual time=0.001..0.001 rows=1 loops=61)

  • Index Cond: (user_id = clps.user_id)
18. 0.138 0.138 ↓ 2.3 256 6

Bitmap Index Scan on idx_56ff5e38166d1f9c (cost=0.00..5.14 rows=113 width=0) (actual time=0.023..0.023 rows=256 loops=6)

  • Index Cond: (project_id = clpp.project_id)
19. 0.061 0.305 ↓ 0.0 0 61

Limit (cost=9.74..13.76 rows=1 width=12) (actual time=0.005..0.005 rows=0 loops=61)

20. 0.061 0.244 ↓ 0.0 0 61

Bitmap Heap Scan on claire_project_completion _cpc_1 (cost=9.74..13.76 rows=1 width=12) (actual time=0.004..0.004 rows=0 loops=61)

  • Recheck Cond: ((user_id = clps.user_id) AND (project_id = clpp.project_id))
  • Filter: (effective_at = clps.followed_at)
21. 0.002 0.183 ↓ 0.0 0 61

BitmapAnd (cost=9.74..9.74 rows=1 width=0) (actual time=0.003..0.003 rows=0 loops=61)

22. 0.061 0.061 ↑ 8.0 1 61

Bitmap Index Scan on idx_56ff5e38a76ed395 (cost=0.00..4.35 rows=8 width=0) (actual time=0.001..0.001 rows=1 loops=61)

  • Index Cond: (user_id = clps.user_id)
23. 0.120 0.120 ↓ 2.3 256 6

Bitmap Index Scan on idx_56ff5e38166d1f9c (cost=0.00..5.14 rows=113 width=0) (actual time=0.020..0.020 rows=256 loops=6)

  • Index Cond: (project_id = clpp.project_id)
Planning time : 0.675 ms
Execution time : 2.370 ms