explain.depesz.com

PostgreSQL's explain analyze made readable

Result: 2Q7Z

Settings
# exclusive inclusive rows x rows loops node
1. 0.001 560.769 ↑ 1.0 1 1

Limit (cost=78,828.81..78,828.82 rows=1 width=8) (actual time=560.769..560.769 rows=1 loops=1)

2. 0.001 560.768 ↑ 369,209.0 1 1

Unique (cost=78,828.81..81,597.88 rows=369,209 width=8) (actual time=560.768..560.768 rows=1 loops=1)

3. 318.183 560.767 ↑ 369,209.0 1 1

Sort (cost=78,828.81..79,751.84 rows=369,209 width=8) (actual time=560.767..560.767 rows=1 loops=1)

  • Sort Key: matr.ip_index, matr.port
  • Sort Method: external merge Disk: 8720kB
4. 59.875 242.584 ↓ 1.3 492,276 1

Append (cost=19.50..39,637.41 rows=369,209 width=8) (actual time=0.075..242.584 rows=492,276 loops=1)

5. 92.845 160.030 ↓ 1.3 491,777 1

Hash Anti Join (cost=19.50..26,754.68 rows=368,864 width=8) (actual time=0.074..160.030 rows=491,777 loops=1)

  • Hash Cond: ((matr.port = n.proxy_port) AND (matr.ip_index = n.ip_index))
6. 67.165 67.165 ↑ 1.0 491,780 1

Seq Scan on all_ip_indexes_ports_matr_view matr (cost=0.00..8,814.50 rows=491,819 width=8) (actual time=0.050..67.165 rows=491,780 loops=1)

  • Filter: ("position" > 500)
  • Rows Removed by Filter: 500
7. 0.006 0.020 ↑ 126.7 3 1

Hash (cost=13.80..13.80 rows=380 width=8) (actual time=0.020..0.020 rows=3 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 9kB
8. 0.014 0.014 ↑ 10.9 35 1

Seq Scan on nats n (cost=0.00..13.80 rows=380 width=8) (actual time=0.007..0.014 rows=35 loops=1)

9. 2.886 22.679 ↓ 1.4 499 1

Gather (cost=1,019.50..7,344.60 rows=345 width=8) (actual time=0.282..22.679 rows=499 loops=1)

  • Workers Planned: 1
  • Workers Launched: 1
10. 0.068 19.793 ↓ 1.2 250 2 / 2

Hash Anti Join (cost=19.50..6,310.10 rows=203 width=8) (actual time=8.715..19.793 rows=250 loops=2)

  • Hash Cond: ((matr_1.port = n_1.proxy_port) AND (matr_1.ip_index = n_1.ip_index))
11. 19.713 19.713 ↑ 1.1 250 2 / 2

Parallel Seq Scan on all_ip_indexes_ports_matr_view matr_1 (cost=0.00..6,280.71 rows=271 width=8) (actual time=8.698..19.713 rows=250 loops=2)

  • Filter: ("position" < 500)
  • Rows Removed by Filter: 245890
12. 0.003 0.012 ↑ 126.7 3 1 / 2

Hash (cost=13.80..13.80 rows=380 width=8) (actual time=0.024..0.024 rows=3 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 9kB
13. 0.009 0.009 ↑ 10.9 35 1 / 2

Seq Scan on nats n_1 (cost=0.00..13.80 rows=380 width=8) (actual time=0.008..0.017 rows=35 loops=1)

Planning time : 0.241 ms
Execution time : 562.134 ms