#2
⏱️ 386.37 мс
select count(*) as "aggregate" from "master_products" where "barcode" is not null and "category_slug" = ? and "subcategory_slug" = ? and "master_products"."id" in ((select "master_product_id" from "store_prices" where "store_id" in (?, ?, ?)) union (select "master_product_id" from "deals" where "is_active" = ? and "store_id" in (?, ?, ?)))
Bindings:
["snacks","chips_savory",462,470,521,true,462,470,521]
#3
⏱️ 348.99 мс
select * from "master_products" where "barcode" is not null and "category_slug" = ? and "subcategory_slug" = ? and "master_products"."id" in ((select "master_product_id" from "store_prices" where "store_id" in (?, ?, ?)) union (select "master_product_id" from "deals" where "is_active" = ? and "store_id" in (?, ?, ?))) order by CASE WHEN master_products.image_url IS NOT NULL AND master_products.image_url != '' THEN 0 ELSE 1 END, "master_products"."id" desc limit 32 offset 0
Bindings:
["snacks","chips_savory",462,470,521,true,462,470,521]
#4
⏱️ 25.64 мс
select * from "deals" where "master_product_id" in (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) and "is_active" = ? and "store_id" in (?, ?, ?)
Bindings:
[208252,208251,197740,165076,134463,132666,131589,130213,130025,128444,128132,127188,126856,124931,124699,124429,124318,123889,123423,122759,122758,115734,115733,115732,115659,115591,115545,114839,114331,113962,113833,113012,true,462,470,521]
#6
⏱️ 14.47 мс
select * from "store_prices" where "master_product_id" in (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) and "price" > ? and "store_id" in (?, ?, ?)
Bindings:
[208252,208251,197740,165076,134463,132666,131589,130213,130025,128444,128132,127188,126856,124931,124699,124429,124318,123889,123423,122759,122758,115734,115733,115732,115659,115591,115545,114839,114331,113962,113833,113012,0,462,470,521]