explain.depesz.com

PostgreSQL's explain analyze made readable

Result: zOy

Settings
# exclusive inclusive rows x rows loops node
1. 0.000 0.000 ↓ 0.0

WindowAgg (cost=236,564,568,276.92..253,447,973,296.85 rows=74,360,000 width=220) (actual rows= loops=)

2. 0.000 0.000 ↓ 0.0

Subquery Scan on final (cost=236,564,568,276.92..253,446,857,896.85 rows=74,360,000 width=212) (actual rows= loops=)

3. 0.000 0.000 ↓ 0.0

GroupAggregate (cost=236,564,568,276.92..253,446,114,296.85 rows=74,360,000 width=180) (actual rows= loops=)

  • Group Key: social_offset_ac.id_user, ((social_offset_ac.gid_entity)::text), (CASE WHEN (sr.gid IS NOT NULL) THEN sr.series_tags ELSE NULL::ltree[] END)
4. 0.000 0.000 ↓ 0.0

Sort (cost=236,564,568,276.92..237,770,260,206.92 rows=482,276,771,998 width=338) (actual rows= loops=)

  • Sort Key: social_offset_ac.id_user, ((social_offset_ac.gid_entity)::text), (CASE WHEN (sr.gid IS NOT NULL) THEN sr.series_tags ELSE NULL::ltree[] END)
5. 0.000 0.000 ↓ 0.0

Merge Right Join (cost=14,112,154.66..9,737,801,857.89 rows=482,276,771,998 width=338) (actual rows= loops=)

  • Merge Cond: ((sr.gid)::ltree = (social_offset_ac.gid_entity)::ltree)
6. 0.000 0.000 ↓ 0.0

Sort (cost=1,790.14..1,836.61 rows=18,590 width=96) (actual rows= loops=)

  • Sort Key: sr.gid
7. 0.000 0.000 ↓ 0.0

Seq Scan on series_releases_ac sr (cost=0.00..471.90 rows=18,590 width=96) (actual rows= loops=)

8. 0.000 0.000 ↓ 0.0

Materialize (cost=14,110,364.52..105,235,938.07 rows=5,188,561,291 width=242) (actual rows= loops=)

9. 0.000 0.000 ↓ 0.0

Merge Left Join (cost=14,110,364.52..92,264,534.84 rows=5,188,561,291 width=242) (actual rows= loops=)

  • Merge Cond: ((social_offset_ac.gid_entity)::ltree = (mr.gid_movie)::ltree)
10. 0.000 0.000 ↓ 0.0

Sort (cost=14,108,912.52..14,271,788.00 rows=65,150,192 width=178) (actual rows= loops=)

  • Sort Key: social_offset_ac.gid_entity
11. 0.000 0.000 ↓ 0.0

Seq Scan on social_offset_ac (cost=0.00..2,262,187.92 rows=65,150,192 width=178) (actual rows= loops=)

12. 0.000 0.000 ↓ 0.0

Sort (cost=1,452.00..1,491.82 rows=15,928 width=64) (actual rows= loops=)

  • Sort Key: mr.gid_movie
13. 0.000 0.000 ↓ 0.0

Seq Scan on movie_releases_ac mr (cost=0.00..340.28 rows=15,928 width=64) (actual rows= loops=)