explain.depesz.com

PostgreSQL's explain analyze made readable

Result: riYp

Settings
# exclusive inclusive rows x rows loops node
1. 0.003 51,346.806 ↓ 10.0 10 1

Limit (cost=67,750.58..67,750.58 rows=1 width=156) (actual time=51,346.805..51,346.806 rows=10 loops=1)

2. 0.050 51,346.803 ↓ 10.0 10 1

Sort (cost=67,750.58..67,750.58 rows=1 width=156) (actual time=51,346.803..51,346.803 rows=10 loops=1)

  • Sort Key: children_camps.""position"", children_camps.id DESC
  • Sort Method: quicksort Memory: 30kB
3. 0.174 51,346.753 ↓ 10.0 10 1

GroupAggregate (cost=3,713.36..67,750.57 rows=1 width=156) (actual time=9,758.662..51,346.753 rows=10 loops=1)

  • Group Key: children_camps.id
4. 0.000 51,346.579 ↓ 11.0 11 1

Nested Loop (cost=3,713.36..67,750.54 rows=1 width=80) (actual time=7,996.375..51,346.579 rows=11 loops=1)

  • Join Filter: (control_object.entity_id = children_camps.id)
  • Rows Removed by Join Filter: 7,910
5. 0.455 0.455 ↓ 89.0 89 1

Index Scan Backward using children_camps_pkey on children_camps (cost=0.14..45.48 rows=1 width=72) (actual time=0.011..0.455 rows=89 loops=1)

  • Filter: (deleted_at IS NULL)
6. 23,127.704 51,355.136 ↑ 6.1 89 89

Gather (cost=3,713.22..67,698.28 rows=543 width=12) (actual time=32.187..577.024 rows=89 loops=89)

  • Workers Planned: 2
  • Workers Launched: 2
7. 8,606.849 28,227.432 ↑ 4.6 49 161 / 3

Hash Join (cost=2,713.22..66,643.98 rows=226 width=12) (actual time=20.798..525.977 rows=49 loops=161)

  • Hash Cond: (conrol_subject_control_object.control_object_id = control_object.id)
8. 19,601.482 19,601.482 ↓ 1.3 2,730,913 161 / 3

Parallel Seq Scan on conrol_subject_control_object (cost=0.00..58,526.95 rows=2,058,595 width=8) (actual time=0.010..365.245 rows=2,730,913 loops=161)

9. 0.462 19.102 ↑ 8.6 89 73 / 3

Hash (cost=2,703.63..2,703.63 rows=767 width=8) (actual time=0.784..0.785 rows=89 loops=73)

  • Buckets: 1,024 Batches: 1 Memory Usage: 12kB
10. 18.639 18.639 ↑ 8.6 89 73 / 3

Index Scan using ix_entity_table_name on control_object (cost=0.56..2,703.63 rows=767 width=8) (actual time=0.080..0.766 rows=89 loops=73)

  • Index Cond: ((entity_table_name)::text = 'children_camps'::text)
Planning time : 0.286 ms
Execution time : 51,356.751 ms