explain.depesz.com

PostgreSQL's explain analyze made readable

Result: 2rx2

Settings
# exclusive inclusive rows x rows loops node
1. 0.009 612.875 ↑ 1.0 100 1

Limit (cost=258,981.77..258,982.02 rows=100 width=4) (actual time=609.346..612.875 rows=100 loops=1)

  • Output: t.id
  • Buffers: shared hit=7,193 read=227,218
2. 0.061 612.866 ↑ 2.0 100 1

Sort (cost=258,981.77..258,982.27 rows=200 width=4) (actual time=609.344..612.866 rows=100 loops=1)

  • Output: t.id
  • Sort Key: t.id
  • Sort Method: top-N heapsort Memory: 33kB
  • Buffers: shared hit=7,193 read=227,218
3. 0.028 612.805 ↓ 1.5 303 1

Subquery Scan on t (cost=0.00..258,974.12 rows=200 width=4) (actual time=609.204..612.805 rows=303 loops=1)

  • Output: t.id
  • Buffers: shared hit=7,193 read=227,218
4. 14.206 612.777 ↓ 1.5 303 1

HashSetOp Except (cost=0.00..258,972.12 rows=200 width=8) (actual time=609.203..612.777 rows=303 loops=1)

  • Output: "*SELECT* 1".id, (0)
  • Buffers: shared hit=7,193 read=227,218
5. 5.944 598.571 ↑ 1.1 81,443 1

Append (cost=0.00..258,740.67 rows=92,579 width=8) (actual time=0.049..598.571 rows=81,443 loops=1)

  • Buffers: shared hit=7,193 read=227,218
6. 0.099 0.189 ↑ 1.0 1,000 1

Subquery Scan on *SELECT* 1 (cost=0.00..20.00 rows=1,000 width=8) (actual time=0.048..0.189 rows=1,000 loops=1)

  • Output: "*SELECT* 1".id, 0
7. 0.090 0.090 ↑ 1.0 1,000 1

Function Scan on pg_catalog.generate_series s (cost=0.00..10.00 rows=1,000 width=4) (actual time=0.047..0.090 rows=1,000 loops=1)

  • Output: s.id
  • Function Call: generate_series(8900000, 8900999)
8. 9.707 592.438 ↑ 1.1 80,443 1

Subquery Scan on *SELECT* 2 (cost=1,000.00..258,257.78 rows=91,579 width=8) (actual time=0.333..592.438 rows=80,443 loops=1)

  • Output: "*SELECT* 2".aktions_key, 1
  • Buffers: shared hit=7,193 read=227,218
9. 0.000 582.731 ↑ 1.1 80,443 1

Gather (cost=1,000.00..257,341.99 rows=91,579 width=4) (actual time=0.332..582.731 rows=80,443 loops=1)

  • Output: ((regel.aktions_key)::integer)
  • Workers Planned: 2
  • Workers Launched: 2
  • Buffers: shared hit=7,193 read=227,218
10. 586.742 586.742 ↑ 1.4 26,814 3 / 3

Parallel Seq Scan on public.regel (cost=0.00..247,184.09 rows=38,158 width=4) (actual time=0.464..586.742 rows=26,814 loops=3)

  • Output: (regel.aktions_key)::integer
  • Filter: ((regel.aktions_key)::text ~ '^8900[0-9]{3}$'::text)
  • Rows Removed by Filter: 778,892
  • Buffers: shared hit=7,193 read=227,218
  • Worker 0: actual time=0.082..597.582 rows=31,546 loops=1
  • Buffers: shared hit=2,376 read=78,873
  • Worker 1: actual time=1.281..597.675 rows=30,950 loops=1
  • Buffers: shared hit=2,322 read=75,498
Planning time : 0.156 ms
Execution time : 612.920 ms