Skip to content

Instantly share code, notes, and snippets.

@mayhem
Created September 15, 2019 19:02
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save mayhem/55c6947bfd8cd22514deb9a1e969d566 to your computer and use it in GitHub Desktop.
Save mayhem/55c6947bfd8cd22514deb9a1e969d566 to your computer and use it in GitHub Desktop.
QUERY PLAN
-------------------------------------------------------------------------------------------------------------------------------------------
GroupAggregate (cost=25445006.19..27648699.60 rows=62962669 width=118)
Group Key: rpr.id, ac.name, r.gid, r.name, a.gid, rl.name, rl.gid
-> Sort (cost=25445006.19..25602412.86 rows=62962669 width=118)
Sort Key: rpr.id, ac.name, r.gid, r.name, a.gid, rl.name, rl.gid
-> Hash Join (cost=1692437.93..5667781.13 rows=62962669 width=118)
Hash Cond: (r.artist_credit = ac.id)
-> Hash Join (cost=1307840.84..4062150.57 rows=23713115 width=81)
Hash Cond: (t.recording = r.id)
-> Hash Join (cost=404696.15..1673037.06 rows=23713115 width=45)
Hash Cond: (t.medium = m.id)
-> Seq Scan on track t (cost=0.00..661339.84 rows=27371384 width=8)
-> Hash (cost=358255.64..358255.64 rows=2181401 width=45)
-> Hash Join (cost=238731.68..358255.64 rows=2181401 width=45)
Hash Cond: (m.release = rl.id)
-> Seq Scan on medium m (cost=0.00..46552.30 rows=2517930 width=8)
-> Hash (cost=195649.74..195649.74 rows=1934875 width=49)
-> Hash Join (cost=103967.87..195649.74 rows=1934875 width=49)
Hash Cond: (rpr.release = rl.id)
-> Seq Scan on recording_pair_releases rpr (cost=0.00..27910.75 rows=1934875 width=8)
-> Hash (cost=56420.72..56420.72 rows=2233372 width=41)
-> Seq Scan on release rl (cost=0.00..56420.72 rows=2233372 width=41)
-> Hash (cost=467404.64..467404.64 rows=20467764 width=44)
-> Seq Scan on recording r (cost=0.00..467404.64 rows=20467764 width=44)
-> Hash (cost=324380.72..324380.72 rows=2704429 width=49)
-> Hash Join (cost=127070.10..324380.72 rows=2704429 width=49)
Hash Cond: (acn.artist_credit = ac.id)
-> Hash Join (cost=65047.32..179082.51 rows=2704429 width=20)
Hash Cond: (acn.artist = a.id)
-> Seq Scan on artist_credit_name acn (cost=0.00..46949.29 rows=2704429 width=8)
-> Hash (cost=37568.81..37568.81 rows=1496681 width=20)
-> Seq Scan on artist a (cost=0.00..37568.81 rows=1496681 width=20)
-> Hash (cost=30866.79..30866.79 rows=1611279 width=29)
-> Seq Scan on artist_credit ac (cost=0.00..30866.79 rows=1611279 width=29)
(33 rows)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment