explain.depesz.com

PostgreSQL's explain analyze made readable

Result: QZos

Settings
# exclusive inclusive rows x rows loops node
1. 176.336 974.386 ↑ 1.9 235,515 1

Merge Left Join (cost=586.42..107,622.66 rows=440,840 width=164) (actual time=125.052..974.386 rows=235,515 loops=1)

  • Merge Cond: (a.id = g.id_produkt)
  • Filter: (((a.nr_umowy IS NOT NULL) AND (a.nr_umowy <> ''::text)) OR ((b.nr_umowy IS NOT NULL) AND (b.nr_umowy <> ''::text)) OR ((c.nr_umowy IS NOT NULL) AND (c.nr_umowy <> ''::text)) OR ((d.nr_umowy IS NOT NULL) AND (d.nr_umowy <> ''::text)) OR ((e.nr_ko (...)
  • Rows Removed by Filter: 279558
2. 73.857 787.080 ↓ 1.2 514,852 1

Merge Left Join (cost=293.53..92,889.25 rows=440,840 width=135) (actual time=13.767..787.080 rows=514,852 loops=1)

  • Merge Cond: (a.id = f.id_produkt)
3. 79.129 699.236 ↓ 1.2 514,755 1

Merge Left Join (cost=1.58..91,440.95 rows=440,840 width=118) (actual time=0.035..699.236 rows=514,755 loops=1)

  • Merge Cond: (a.id = e.id_produkt)
4. 80.581 603.921 ↓ 1.1 500,449 1

Merge Left Join (cost=1.29..88,470.14 rows=440,840 width=106) (actual time=0.030..603.921 rows=500,449 loops=1)

  • Merge Cond: (a.id = d.id_produkt)
5. 78.253 495.644 ↓ 1.1 483,334 1

Merge Left Join (cost=1.00..82,940.06 rows=440,840 width=76) (actual time=0.025..495.644 rows=483,334 loops=1)

  • Merge Cond: (a.id = c.id_produkt)
6. 120.371 351.870 ↓ 1.0 446,542 1

Merge Left Join (cost=0.71..75,699.05 rows=440,840 width=46) (actual time=0.019..351.870 rows=446,542 loops=1)

  • Merge Cond: (a.id = b.id_produkt)
7. 221.351 221.351 ↑ 1.0 440,840 1

Index Scan using bp_produkt_pkey on bp_produkt a (cost=0.42..73,372.19 rows=440,840 width=41) (actual time=0.009..221.351 rows=440,840 loops=1)

8. 10.148 10.148 ↑ 1.0 24,876 1

Index Scan using idxbp_produkt_27_umowa_id_produkt on bp_produkt_27_umowa b (cost=0.29..913.81 rows=24,876 width=13) (actual time=0.007..10.148 rows=24,876 loops=1)

9. 65.521 65.521 ↑ 1.0 83,093 1

Index Scan using idxbp_produkt_32_umowa_id_produkt on bp_produkt_32_umowa c (cost=0.29..5,100.25 rows=83,093 width=38) (actual time=0.006..65.521 rows=83,093 loops=1)

10. 27.696 27.696 ↑ 1.0 78,275 1

Index Scan using idxbp_produkt_41_umowa_id_produkt on bp_produkt_41_umowa d (cost=0.29..3,449.54 rows=78,275 width=38) (actual time=0.005..27.696 rows=78,275 loops=1)

11. 16.186 16.186 ↑ 1.0 32,050 1

Index Scan using idxbp_produkt_47_umowa_id_produkt on bp_produkt_47_umowa e (cost=0.29..1,468.57 rows=32,050 width=20) (actual time=0.005..16.186 rows=32,050 loops=1)

12. 0.986 13.987 ↑ 1.0 3,617 1

Sort (cost=291.95..300.99 rows=3,617 width=25) (actual time=13.731..13.987 rows=3,617 loops=1)

  • Sort Key: f.id_produkt
  • Sort Method: quicksort Memory: 379kB
13. 13.001 13.001 ↑ 1.0 3,617 1

Seq Scan on bp_produkt_48_umowa f (cost=0.00..78.17 rows=3,617 width=25) (actual time=5.746..13.001 rows=3,617 loops=1)

14. 1.131 10.970 ↑ 1.0 3,485 1

Sort (cost=292.89..301.60 rows=3,485 width=37) (actual time=10.614..10.970 rows=3,485 loops=1)

  • Sort Key: g.id_produkt
  • Sort Method: quicksort Memory: 369kB
15. 9.839 9.839 ↑ 1.0 3,485 1

Seq Scan on bp_produkt_50_umowa g (cost=0.00..87.85 rows=3,485 width=37) (actual time=2.088..9.839 rows=3,485 loops=1)

Planning time : 219.799 ms