explain.depesz.com

PostgreSQL's explain analyze made readable

Result: iYwWm

Settings
# exclusive inclusive rows x rows loops node
1. 955.321 19,767.329 ↓ 2.5 2,265,951 1

Hash Join (cost=52,683.28..156,847.23 rows=895,628 width=112) (actual time=7,265.511..19,767.329 rows=2,265,951 loops=1)

  • Buffers: shared hit=478553 read=45256, temp read=27533 written=27534
2. 730.680 18,810.034 ↓ 2.5 2,265,951 1

Hash Join (cost=52,536.47..154,349.09 rows=895,628 width=144) (actual time=7,263.52..18,810.034 rows=2,265,951 loops=1)

  • Buffers: shared hit=478550 read=45240, temp read=27533 written=27534
3. 724.258 18,079.350 ↓ 2.5 2,265,951 1

Hash Join (cost=52,517.02..151,978.32 rows=895,628 width=128) (actual time=7,263.511..18,079.35 rows=2,265,951 loops=1)

  • Buffers: shared hit=478550 read=45240, temp read=27533 written=27534
4. 685.455 17,355.089 ↓ 2.5 2,265,951 1

Hash Join (cost=52,496.67..149,606.65 rows=895,628 width=112) (actual time=7,263.502..17,355.089 rows=2,265,951 loops=1)

  • Buffers: shared hit=478550 read=45240, temp read=27533 written=27534
5. 1,166.482 16,669.404 ↓ 2.5 2,265,951 1

Merge Join (cost=52,475.19..147,233.84 rows=895,628 width=96) (actual time=7,263.257..16,669.404 rows=2,265,951 loops=1)

  • Buffers: shared hit=478542 read=45240, temp read=27533 written=27534
6. 4,501.181 12,549.365 ↓ 123.3 3,733,301 1

Merge Join (cost=52,407.7..53,315.98 rows=30,273 width=64) (actual time=7,262.901..12,549.365 rows=3,733,301 loops=1)

  • Buffers: shared hit=59 read=25571, temp read=27533 written=27534
7. 4,662.131 8,043.702 ↓ 123.3 3,733,301 1

Sort (cost=52,283.82..52,359.5 rows=30,273 width=49) (actual time=7,260.082..8,043.702 rows=3,733,301 loops=1)

  • Sort Key: price_default_1.price_id
  • Sort Method: external merge Disk: 220264kB
  • Buffers: shared hit=59 read=25541, temp read=27533 written=27534
8. 1,268.480 3,381.571 ↓ 123.3 3,733,353 1

Hash Join (cost=462.06..50,030.64 rows=30,273 width=49) (actual time=9.939..3,381.571 rows=3,733,353 loops=1)

  • Buffers: shared hit=59 read=25541
9. 588.824 2,109.016 ↓ 101.1 1,547,884 1

Hash Join (cost=287.19..49,457.33 rows=15,311 width=76) (actual time=5.844..2,109.016 rows=1,547,884 loops=1)

  • Buffers: shared hit=57 read=25495
10. 763.872 1,517.826 ↓ 99.4 1,547,884 1

Hash Join (cost=188.97..49,318.21 rows=15,567 width=60) (actual time=3.458..1,517.826 rows=1,547,884 loops=1)

  • Buffers: shared hit=54 read=25485
11. 202.370 750.690 ↑ 1.0 1,547,884 1

Append (cost=0..40,998.34 rows=1,548,734 width=55) (actual time=0.164..750.69 rows=1,547,884 loops=1)

  • Buffers: shared hit=6 read=25485
12. 0.599 0.599 ↑ 1.0 599 1

Seq Scan on price_default price_default_1 (cost=0..13.99 rows=599 width=54) (actual time=0.163..0.599 rows=599 loops=1)

  • Buffers: shared hit=2 read=6
13. 546.131 546.131 ↓ 1.0 1,542,993 1

Seq Scan on price_sale price_sale_1 (cost=0..40,841.63 rows=1,542,963 width=55) (actual time=0.164..546.131 rows=1,542,993 loops=1)

  • Buffers: shared hit=2 read=25410
14. 0.004 0.004 ↓ 0.0 0 1

Seq Scan on price_company price_company_1 (cost=0..14.2 rows=420 width=80) (actual time=0.004..0.004 rows=0 loops=1)

15. 0.002 0.002 ↓ 0.0 0 1

Seq Scan on price_list price_list_1 (cost=0..14.6 rows=460 width=80) (actual time=0.002..0.002 rows=0 loops=1)

16. 1.584 1.584 ↑ 1.0 4,292 1

Seq Scan on price_class price_class_1 (cost=0..113.92 rows=4,292 width=54) (actual time=0.138..1.584 rows=4,292 loops=1)

  • Buffers: shared hit=2 read=69
17. 2.261 3.264 ↑ 1.0 5,639 1

Hash (cost=104.39..104.39 rows=5,639 width=37) (actual time=3.264..3.264 rows=5,639 loops=1)

  • Buffers: shared hit=48
18. 1.003 1.003 ↑ 1.0 5,639 1

Seq Scan on product_uom_conversion suomc (cost=0..104.39 rows=5,639 width=37) (actual time=0.006..1.003 rows=5,639 loops=1)

  • Buffers: shared hit=48
19. 1.134 2.366 ↑ 1.0 2,852 1

Hash (cost=62.56..62.56 rows=2,852 width=16) (actual time=2.366..2.366 rows=2,852 loops=1)

  • Buffers: shared hit=3 read=10
20. 1.232 1.232 ↑ 1.0 2,852 1

Index Only Scan using product_pkey on product pro (cost=0.28..62.56 rows=2,852 width=16) (actual time=0.288..1.232 rows=2,852 loops=1)

  • Buffers: shared hit=3 read=10
21. 2.021 4.075 ↑ 1.0 5,639 1

Hash (cost=104.39..104.39 rows=5,639 width=37) (actual time=4.075..4.075 rows=5,639 loops=1)

  • Buffers: shared hit=2 read=46
22. 2.054 2.054 ↑ 1.0 5,639 1

Seq Scan on product_uom_conversion tuomc (cost=0..104.39 rows=5,639 width=37) (actual time=0.18..2.054 rows=5,639 loops=1)

  • Buffers: shared hit=2 read=46
23. 3.009 4.482 ↓ 6.5 6,953 1

Sort (cost=123.88..126.55 rows=1,069 width=27) (actual time=2.807..4.482 rows=6,953 loops=1)

  • Sort Key: pm.price_id
  • Sort Method: quicksort Memory: 347kB
  • Buffers: shared read=30
24. 1.473 1.473 ↓ 3.0 3,205 1

Seq Scan on price_modified pm (cost=0..70.1 rows=1,069 width=27) (actual time=0.299..1.473 rows=3,205 loops=1)

  • Filter: upper_inf(pm.active_range)
  • Buffers: shared read=30
25. 375.758 2,953.557 ↓ 2.5 2,265,950 1

Materialize (cost=67.5..83,521.39 rows=895,628 width=48) (actual time=0.248..2,953.557 rows=2,265,950 loops=1)

  • Buffers: shared hit=478483 read=19669
26. 494.161 2,577.799 ↑ 1.0 895,582 1

Merge Join (cost=67.5..81,282.32 rows=895,628 width=48) (actual time=0.245..2,577.799 rows=895,582 loops=1)

  • Buffers: shared hit=478483 read=19669
27. 1,320.695 1,320.695 ↑ 1.0 895,582 1

Index Scan using idx_claim_product_price_price_id on claim_product_price claim_product_price (cost=0.42..30,173.34 rows=895,628 width=32) (actual time=0.016..1,320.695 rows=895,582 loops=1)

  • Buffers: shared hit=474927 read=11128
28. 762.943 762.943 ↓ 1.0 1,542,971 1

Index Only Scan using price_generated_pkey on price_sale price_sale (cost=0.43..36,122.87 rows=1,542,963 width=16) (actual time=0.218..762.943 rows=1,542,971 loops=1)

  • Buffers: shared hit=3556 read=8541
29. 0.116 0.230 ↑ 1.0 599 1

Hash (cost=13.99..13.99 rows=599 width=16) (actual time=0.23..0.23 rows=599 loops=1)

  • Buffers: shared hit=8
30. 0.114 0.114 ↑ 1.0 599 1

Seq Scan on price_default price_default (cost=0..13.99 rows=599 width=16) (actual time=0.006..0.114 rows=599 loops=1)

  • Buffers: shared hit=8
31. 0.001 0.003 ↓ 0.0 0 1

Hash (cost=14.6..14.6 rows=460 width=16) (actual time=0.003..0.003 rows=0 loops=1)

32. 0.002 0.002 ↓ 0.0 0 1

Seq Scan on price_list price_list (cost=0..14.6 rows=460 width=16) (actual time=0.002..0.002 rows=0 loops=1)

33. 0.001 0.004 ↓ 0.0 0 1

Hash (cost=14.2..14.2 rows=420 width=16) (actual time=0.004..0.004 rows=0 loops=1)

34. 0.003 0.003 ↓ 0.0 0 1

Seq Scan on price_company price_company (cost=0..14.2 rows=420 width=16) (actual time=0.003..0.003 rows=0 loops=1)

35. 0.911 1.974 ↑ 1.0 4,292 1

Hash (cost=93.16..93.16 rows=4,292 width=16) (actual time=1.974..1.974 rows=4,292 loops=1)

  • Buffers: shared hit=3 read=16
36. 1.063 1.063 ↑ 1.0 4,292 1

Index Only Scan using price_class_pkey on price_class price_class (cost=0.28..93.16 rows=4,292 width=16) (actual time=0.218..1.063 rows=4,292 loops=1)

  • Buffers: shared hit=3 read=16