explain.depesz.com

PostgreSQL's explain analyze made readable

Result: 99Dr : Optimization for: plan #lYHc

Settings

Optimization path:

Optimization(s) for this plan:

# exclusive inclusive rows x rows loops node
1. 0.819 241.345 ↑ 1.9 483 1

Sort (cost=27,867.82..27,870.15 rows=929 width=1,061) (actual time=241.241..241.345 rows=483 loops=1)

  • Sort Key: shop_catalog_product.is_main_color_variant DESC
  • Sort Method: quicksort Memory: 819kB
2. 10.987 240.526 ↑ 1.9 483 1

Hash Join (cost=21,988.25..27,822.02 rows=929 width=1,061) (actual time=185.735..240.526 rows=483 loops=1)

  • Hash Cond: (shop_catalog_product.id = shop_catalog_productsupplierinfo.product_id)
3. 43.936 43.936 ↓ 1.0 96,078 1

Seq Scan on shop_catalog_product (cost=0.00..5,464.34 rows=96,038 width=224) (actual time=0.062..43.936 rows=96,078 loops=1)

  • Filter: is_main_size_variant
  • Rows Removed by Filter: 37,056
4. 2.959 185.603 ↓ 1.5 1,971 1

Hash (cost=21,972.15..21,972.15 rows=1,288 width=837) (actual time=185.603..185.603 rows=1,971 loops=1)

  • Buckets: 2,048 Batches: 1 Memory Usage: 1,978kB
5. 182.644 182.644 ↓ 1.5 1,971 1

Seq Scan on shop_catalog_productsupplierinfo (cost=0.00..21,972.15 rows=1,288 width=837) (actual time=2.186..182.644 rows=1,971 loops=1)

  • Filter: ((remote_color_group_id IS NOT NULL) AND ((remote_color_group_id)::text = ANY ('{makros-3879822,1-000021900,makros-5944421,makros-6307900,884,1-000032034,1013,36842,108239,1-000016584,00000004253,makros-8234375,makros-4605364,makros-8469708,makros-6653143,makros-2870184,makros-9756433,makros-1144739,00000003847,701825,105977,makros-1550214,893,105082,36459,00000008288,makros-1895838,00000000386,160387,makros-7383248,makros-3915666,76158,60029,makros-7621158,00000011966,makros-9669287,makros-5140298,makros-5042068,39706}'::text[])))
  • Rows Removed by Filter: 131,155
Planning time : 1.818 ms
Execution time : 241.977 ms