explain.depesz.com

PostgreSQL's explain analyze made readable

Result: BQbQ

Settings
# exclusive inclusive rows x rows loops node
1. 0.004 7,207.477 ↑ 1.0 20 1

Limit (cost=373,163.89..373,163.94 rows=20 width=144) (actual time=7,207.469..7,207.477 rows=20 loops=1)

2. 74.535 7,207.473 ↑ 11,413.0 20 1

Sort (cost=373,163.89..373,734.54 rows=228,259 width=144) (actual time=7,207.469..7,207.473 rows=20 loops=1)

  • Sort Key: products.grow_all_order DESC NULLS LAST
  • Sort Method: top-N heapsort Memory: 44kB
3. 3,559.588 7,132.938 ↑ 1.0 221,499 1

Hash Join (cost=317,403.20..367,090.00 rows=228,259 width=144) (actual time=3,583.103..7,132.938 rows=221,499 loops=1)

  • Hash Cond: (mp.product_id = products.product_id)
4. 71.319 87.590 ↑ 1.0 221,499 1

Bitmap Heap Scan on wp_pidi_category_parent_product_aliexpress mp (cost=5,021.44..24,525.67 rows=228,259 width=8) (actual time=19.108..87.590 rows=221,499 loops=1)

  • Recheck Cond: (parent = 15)
  • Heap Blocks: exact=16651
5. 16.271 16.271 ↑ 1.0 221,499 1

Bitmap Index Scan on tree_product_index (cost=0.00..4,964.37 rows=228,259 width=0) (actual time=16.271..16.271 rows=221,499 loops=1)

  • Index Cond: (parent = 15)
6. 2,737.021 3,485.760 ↑ 1.0 1,231,723 1

Hash (cost=271,725.23..271,725.23 rows=1,231,723 width=144) (actual time=3,485.760..3,485.760 rows=1,231,723 loops=1)

  • Buckets: 32768 (originally 32768) Batches: 256 (originally 64) Memory Usage: 3841kB
7. 748.739 748.739 ↑ 1.0 1,231,723 1

Seq Scan on wp_pidi_product_aliexpress products (cost=0.00..271,725.23 rows=1,231,723 width=144) (actual time=0.122..748.739 rows=1,231,723 loops=1)