explain.depesz.com

PostgreSQL's explain analyze made readable

Result: AhGR

Settings
# exclusive inclusive rows x rows loops node
1. 4,003.230 44,057.350 ↑ 1.0 12,659,510 1

Merge Left Join (cost=2,318,268.76..2,539,912.15 rows=12,659,510 width=191) (actual time=30,317.535..44,057.350 rows=12,659,510 loops=1)

  • Merge Cond: ((uha.gid_entity)::ltree = (p.gid_entity)::ltree)
2. 3,974.029 39,798.636 ↑ 1.0 12,659,510 1

Merge Left Join (cost=2,315,300.11..2,455,689.65 rows=12,659,510 width=124) (actual time=30,306.231..39,798.636 rows=12,659,510 loops=1)

  • Merge Cond: ((uha.gid_entity)::ltree = (r.gid_movie)::ltree)
3. 32,935.805 35,531.272 ↑ 1.0 12,659,510 1

Sort (cost=2,310,489.21..2,342,137.98 rows=12,659,510 width=115) (actual time=30,284.807..35,531.272 rows=12,659,510 loops=1)

  • Sort Key: uha.gid_entity
  • Sort Method: external merge Disk: 1635016kB
4. 2,595.467 2,595.467 ↑ 1.0 12,659,510 1

Seq Scan on social_action uha (cost=0.00..360,876.10 rows=12,659,510 width=115) (actual time=0.033..2,595.467 rows=12,659,510 loops=1)

5. 283.557 293.335 ↓ 119.4 5,895,702 1

Sort (cost=4,810.90..4,934.39 rows=49,396 width=41) (actual time=21.414..293.335 rows=5,895,702 loops=1)

  • Sort Key: r.gid_movie
  • Sort Method: quicksort Memory: 5065kB
6. 9.778 9.778 ↑ 1.1 45,169 1

Seq Scan on social_releases r (cost=0.00..959.96 rows=49,396 width=41) (actual time=0.370..9.778 rows=45,169 loops=1)

7. 250.444 255.484 ↓ 177.1 5,629,951 1

Sort (cost=2,968.65..3,048.11 rows=31,784 width=34) (actual time=11.298..255.484 rows=5,629,951 loops=1)

  • Sort Key: p.gid_entity
  • Sort Method: quicksort Memory: 3059kB
8. 5.040 5.040 ↑ 1.1 29,317 1

Seq Scan on social_products p (cost=0.00..591.84 rows=31,784 width=34) (actual time=0.267..5.040 rows=29,317 loops=1)