explain.depesz.com

PostgreSQL's explain analyze made readable

Result: W3is

Settings
# exclusive inclusive rows x rows loops node
1. 0.192 4.863 ↓ 1.2 24 1

Limit (cost=90.99..91.04 rows=20 width=4,798) (actual time=4.587..4.863 rows=24 loops=1)

2. 0.349 4.671 ↓ 1.2 24 1

Sort (cost=90.99..91.04 rows=20 width=4,798) (actual time=4.577..4.671 rows=24 loops=1)

  • Sort Key: assignment_groups."position", assignments."position"
  • Sort Method: quicksort Memory: 44kB
3. 0.309 4.322 ↓ 1.2 24 1

Hash Left Join (cost=82.34..90.56 rows=20 width=4,798) (actual time=3.934..4.322 rows=24 loops=1)

  • Hash Cond: (assignments.assignment_group_id = assignment_groups.id)
4. 0.327 2.570 ↓ 1.2 24 1

Hash Right Join (cost=72.61..80.55 rows=20 width=4,130) (actual time=2.447..2.570 rows=24 loops=1)

  • Hash Cond: (rubrics.id = rubric_associations_assignments_join.rubric_id)
5. 0.182 0.182 ↑ 1.2 41 1

Seq Scan on rubrics (cost=0.00..7.50 rows=50 width=1,004) (actual time=0.006..0.182 rows=41 loops=1)

6. 0.144 2.061 ↓ 1.2 24 1

Hash (cost=72.36..72.36 rows=20 width=3,134) (actual time=2.061..2.061 rows=24 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 11kB
7. 0.389 1.917 ↓ 1.2 24 1

Hash Right Join (cost=67.76..72.36 rows=20 width=3,134) (actual time=1.791..1.917 rows=24 loops=1)

  • Hash Cond: (rubric_associations_assignments_join.association_id = assignments.id)
  • Join Filter: ((rubric_associations.purpose)::text = 'grading'::text)
8. 0.264 0.264 ↓ 1.1 59 1

Seq Scan on rubric_associations rubric_associations_assignments_join (cost=0.00..4.38 rows=56 width=16) (actual time=0.015..0.264 rows=59 loops=1)

  • Filter: ((association_type)::text = 'Assignment'::text)
  • Rows Removed by Filter: 41
9. 0.147 1.264 ↓ 1.2 24 1

Hash (cost=67.51..67.51 rows=20 width=3,126) (actual time=1.264..1.264 rows=24 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 11kB
10. 0.394 1.117 ↓ 1.2 24 1

Hash Right Join (cost=62.75..67.51 rows=20 width=3,126) (actual time=0.993..1.117 rows=24 loops=1)

  • Hash Cond: (rubric_associations.association_id = assignments.id)
11. 0.285 0.285 ↓ 2.1 59 1

Seq Scan on rubric_associations (cost=0.00..4.65 rows=28 width=695) (actual time=0.024..0.285 rows=59 loops=1)

  • Filter: (((purpose)::text = 'grading'::text) AND ((association_type)::text = 'Assignment'::text))
  • Rows Removed by Filter: 41
12. 0.221 0.438 ↓ 1.2 24 1

Hash (cost=62.50..62.50 rows=20 width=2,431) (actual time=0.438..0.438 rows=24 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 11kB
13. 0.170 0.217 ↓ 1.2 24 1

Bitmap Heap Scan on assignments (cost=4.52..62.50 rows=20 width=2,431) (actual time=0.076..0.217 rows=24 loops=1)

  • Recheck Cond: ((context_id = 24) AND ((context_type)::text = 'Course'::text))
  • Filter: (((workflow_state)::text <> 'deleted'::text) AND ((workflow_state)::text = 'published'::text))
14. 0.047 0.047 ↑ 1.0 24 1

Bitmap Index Scan on index_assignments_on_context_id_and_context_type (cost=0.00..4.52 rows=24 width=0) (actual time=0.047..0.047 rows=24 loops=1)

  • Index Cond: ((context_id = 24) AND ((context_type)::text = 'Course'::text))
15. 0.764 1.443 ↓ 1.0 169 1

Hash (cost=7.66..7.66 rows=166 width=668) (actual time=1.443..1.443 rows=169 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 30kB
16. 0.679 0.679 ↓ 1.0 169 1

Seq Scan on assignment_groups (cost=0.00..7.66 rows=166 width=668) (actual time=0.008..0.679 rows=169 loops=1)