explain.depesz.com

PostgreSQL's explain analyze made readable

Result: jhtG

Settings
# exclusive inclusive rows x rows loops node
1. 153.448 1,010.266 ↓ 0.0 0 1

Delete on public.fact_sale (cost=19,066.51..246,990.85 rows=100,000 width=34) (actual time=1,010.266..1,010.266 rows=0 loops=1)

  • Buffers: shared hit=605012 read=3775
2. 55.046 856.818 ↑ 1.0 100,000 1

Nested Loop (cost=19,066.51..246,990.85 rows=100,000 width=34) (actual time=250.513..856.818 rows=100,000 loops=1)

  • Output: fact_sale.ctid, "ANY_subquery".*
  • Inner Unique: true
  • Buffers: shared hit=405012 read=3775
3. 106.105 301.772 ↑ 1.0 100,000 1

HashAggregate (cost=19,066.08..20,066.08 rows=100,000 width=32) (actual time=250.481..301.772 rows=100,000 loops=1)

  • Output: "ANY_subquery".*, "ANY_subquery".sale_sk
  • Group Key: "ANY_subquery".sale_sk
  • Buffers: shared hit=5001 read=3511
4. 46.600 195.667 ↑ 1.0 100,000 1

Subquery Scan on ANY_subquery (cost=0.00..18,816.08 rows=100,000 width=32) (actual time=0.199..195.667 rows=100,000 loops=1)

  • Output: "ANY_subquery".*, "ANY_subquery".sale_sk
  • Buffers: shared hit=5001 read=3511
5. 19.991 149.067 ↑ 1.0 100,000 1

Limit (cost=0.00..17,816.08 rows=100,000 width=4) (actual time=0.194..149.067 rows=100,000 loops=1)

  • Output: fact_sale_1.sale_sk
  • Buffers: shared hit=5001 read=3511
6. 129.076 129.076 ↑ 20.3 100,000 1

Seq Scan on public.fact_sale fact_sale_1 (cost=0.00..361,811.90 rows=2,030,817 width=4) (actual time=0.193..129.076 rows=100,000 loops=1)

  • Output: fact_sale_1.sale_sk
  • Filter: (fact_sale_1.client_sk = 8)
  • Rows Removed by Filter: 285508
  • Buffers: shared hit=5001 read=3511
7. 500.000 500.000 ↑ 1.0 1 100,000

Index Scan using fact_sale_pkey on public.fact_sale (cost=0.43..2.29 rows=1 width=10) (actual time=0.005..0.005 rows=1 loops=100,000)

  • Output: fact_sale.ctid, fact_sale.sale_sk
  • Index Cond: (fact_sale.sale_sk = "ANY_subquery".sale_sk)
  • Buffers: shared hit=400011 read=264
Planning time : 0.334 ms
Execution time : 1,014.176 ms