explain.depesz.com

PostgreSQL's explain analyze made readable

Result: ecHO

Settings
# exclusive inclusive rows x rows loops node
1. 14.812 21.802 ↑ 83.3 60,000 1

Nested Loop (cost=119.67..62,722.17 rows=5,000,000 width=12) (actual time=0.379..21.802 rows=60,000 loops=1)

2. 0.090 0.090 ↑ 3.3 300 1

Function Scan on generate_series b (cost=0.00..10.00 rows=1,000 width=4) (actual time=0.050..0.090 rows=300 loops=1)

3. 6.373 6.900 ↑ 25.0 200 300

Materialize (cost=119.66..224.66 rows=5,000 width=8) (actual time=0.001..0.023 rows=200 loops=300)

4. 0.160 0.527 ↑ 25.0 200 1

Merge Join (cost=119.66..199.66 rows=5,000 width=8) (actual time=0.325..0.527 rows=200 loops=1)

  • Merge Cond: (a.a = c.c)
5. 0.073 0.133 ↑ 5.0 200 1

Sort (cost=59.83..62.33 rows=1,000 width=4) (actual time=0.111..0.133 rows=200 loops=1)

  • Sort Key: a.a
  • Sort Method: quicksort Memory: 34kB
6. 0.060 0.060 ↑ 5.0 200 1

Function Scan on generate_series a (cost=0.00..10.00 rows=1,000 width=4) (actual time=0.036..0.060 rows=200 loops=1)

7. 0.115 0.234 ↑ 5.0 201 1

Sort (cost=59.83..62.33 rows=1,000 width=4) (actual time=0.209..0.234 rows=201 loops=1)

  • Sort Key: c.c
  • Sort Method: quicksort Memory: 43kB
8. 0.119 0.119 ↑ 2.5 400 1

Function Scan on generate_series c (cost=0.00..10.00 rows=1,000 width=4) (actual time=0.073..0.119 rows=400 loops=1)

Planning time : 0.133 ms
Execution time : 26.116 ms