explain.depesz.com

PostgreSQL's explain analyze made readable

Result: WslA

Settings
# exclusive inclusive rows x rows loops node
1. 0.000 1,071.203 ↑ 267.2 4 1

Finalize GroupAggregate (cost=42,354.34..42,502.48 rows=1,069 width=248) (actual time=1,070.204..1,071.203 rows=4 loops=1)

  • Group Key: n1.n_name, n2.n_name, (date_part('year'::text, (lineitem.l_shipdate)::timestamp without time zone))
  • Buffers: shared hit=77899 read=5545
2. 0.000 1,123.104 ↑ 74.2 12 1

Gather Merge (cost=42,354.34..42,472.64 rows=890 width=248) (actual time=1,069.398..1,123.104 rows=12 loops=1)

  • Workers Planned: 2
  • Workers Launched: 2
  • Buffers: shared hit=215121 read=15059
3. 4.128 2,842.329 ↑ 111.2 4 3

Partial GroupAggregate (cost=41,354.32..41,369.89 rows=445 width=248) (actual time=946.435..947.443 rows=4 loops=3)

  • Group Key: n1.n_name, n2.n_name, (date_part('year'::text, (lineitem.l_shipdate)::timestamp without time zone))
  • Buffers: shared hit=215121 read=15059
4. 7.863 2,838.201 ↑ 1.3 343 3

Sort (cost=41,354.32..41,355.43 rows=445 width=228) (actual time=946.001..946.067 rows=343 loops=3)

  • Sort Key: n1.n_name, n2.n_name, (date_part('year'::text, (lineitem.l_shipdate)::timestamp without time zone))
  • Sort Method: quicksort Memory: 79kB
  • Buffers: shared hit=215121 read=15059
5. 21.195 2,830.338 ↑ 1.3 343 3

Hash Join (cost=374.34..41,334.74 rows=445 width=228) (actual time=16.429..943.446 rows=343 loops=3)

  • Hash Cond: (customer.c_nationkey = n2.n_nationkey)
  • Join Filter: (((n1.n_name = 'INDIA'::bpchar) AND (n2.n_name = 'FRANCE'::bpchar)) OR ((n1.n_name = 'FRANCE'::bpchar) AND (n2.n_name = 'INDIA'::bpchar)))
  • Rows Removed by Join Filter: 335
  • Buffers: shared hit=215087 read=15059
6. 64.725 2,807.901 ↑ 1.2 8,665 3

Nested Loop (cost=372.94..41,303.00 rows=10,705 width=128) (actual time=15.149..935.967 rows=8,665 loops=3)

  • Buffers: shared hit=215050 read=15059
7. 60.407 2,431.224 ↑ 1.2 8,665 3

Nested Loop (cost=372.52..36,451.80 rows=10,705 width=128) (actual time=15.077..810.408 rows=8,665 loops=3)

  • Buffers: shared hit=110914 read=15059
8. 152.100 2,032.869 ↑ 1.2 8,665 3

Hash Join (cost=372.10..28,761.53 rows=10,705 width=128) (actual time=14.681..677.623 rows=8,665 loops=3)

  • Hash Cond: (lineitem.l_suppkey = supplier.s_suppkey)
  • Buffers: shared hit=6861 read=15059
9. 1,837.557 1,837.557 ↑ 1.3 106,367 3

Parallel Seq Scan on lineitem (cost=0.00..27,780.60 rows=133,808 width=32) (actual time=0.191..612.519 rows=106,367 loops=3)

  • Filter: ((l_shipdate >= '1995-01-01'::date) AND (l_shipdate <= '1996-12-31'::date))
  • Rows Removed by Filter: 243158
  • Buffers: shared hit=6168 read=15059
10. 2.400 43.212 ↓ 1.0 817 3

Hash (cost=362.10..362.10 rows=800 width=108) (actual time=14.403..14.404 rows=817 loops=3)

  • Buckets: 1024 Batches: 1 Memory Usage: 58kB
  • Buffers: shared hit=693
11. 16.974 40.812 ↓ 1.0 817 3

Hash Join (cost=1.40..362.10 rows=800 width=108) (actual time=0.399..13.604 rows=817 loops=3)

  • Hash Cond: (supplier.s_nationkey = n1.n_nationkey)
  • Buffers: shared hit=693
12. 23.682 23.682 ↑ 1.0 10,000 3

Seq Scan on supplier (cost=0.00..330.00 rows=10,000 width=12) (actual time=0.294..7.894 rows=10,000 loops=3)

  • Buffers: shared hit=690
13. 0.054 0.156 ↑ 1.0 2 3

Hash (cost=1.38..1.38 rows=2 width=108) (actual time=0.052..0.052 rows=2 loops=3)

  • Buckets: 1024 Batches: 1 Memory Usage: 9kB
  • Buffers: shared hit=3
14. 0.102 0.102 ↑ 1.0 2 3

Seq Scan on nation n1 (cost=0.00..1.38 rows=2 width=108) (actual time=0.025..0.034 rows=2 loops=3)

  • Filter: ((n_name = 'INDIA'::bpchar) OR (n_name = 'FRANCE'::bpchar))
  • Rows Removed by Filter: 23
  • Buffers: shared hit=3
15. 337.948 337.948 ↑ 1.0 1 25,996

Index Scan using orders_pkey on orders (cost=0.42..0.72 rows=1 width=12) (actual time=0.013..0.013 rows=1 loops=25,996)

  • Index Cond: (o_orderkey = lineitem.l_orderkey)
  • Buffers: shared hit=104053
16. 311.952 311.952 ↑ 1.0 1 25,996

Index Scan using customer_pkey on customer (cost=0.42..0.45 rows=1 width=12) (actual time=0.012..0.012 rows=1 loops=25,996)

  • Index Cond: (c_custkey = orders.o_custkey)
  • Buffers: shared hit=104136
17. 0.072 1.242 ↑ 1.0 2 3

Hash (cost=1.38..1.38 rows=2 width=108) (actual time=0.414..0.414 rows=2 loops=3)

  • Buckets: 1024 Batches: 1 Memory Usage: 9kB
  • Buffers: shared hit=3
18. 1.170 1.170 ↑ 1.0 2 3

Seq Scan on nation n2 (cost=0.00..1.38 rows=2 width=108) (actual time=0.372..0.390 rows=2 loops=3)

  • Filter: ((n_name = 'FRANCE'::bpchar) OR (n_name = 'INDIA'::bpchar))
  • Rows Removed by Filter: 23
  • Buffers: shared hit=3