#2
⏱️ 473.61 мс
select count(*) as "aggregate" from "master_products" where "barcode" is not null and "category_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:
["grocery",646,142,true,646,142]
#3
⏱️ 569.16 мс
select * from "master_products" where "barcode" is not null and "category_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:
["grocery",646,142,true,646,142]
#4
⏱️ 14.69 мс
select * from "deals" where "master_product_id" in (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) and "is_active" = ? and "store_id" in (?, ?)
Bindings:
[4533815,2049531,2045396,1058113,1002326,951299,948398,913087,825495,750012,737768,737188,737010,715635,715419,711551,689451,685427,684458,600064,545496,493305,480632,412868,403505,397672,395531,379777,373874,367682,364789,364308,true,646,142]
#6
⏱️ 21.29 мс
select * from "store_prices" where "master_product_id" in (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) and "price" > ? and "store_id" in (?, ?)
Bindings:
[4533815,2049531,2045396,1058113,1002326,951299,948398,913087,825495,750012,737768,737188,737010,715635,715419,711551,689451,685427,684458,600064,545496,493305,480632,412868,403505,397672,395531,379777,373874,367682,364789,364308,0,646,142]
#9
⏱️ 20.82 мс
select store_id, count(*) as total from "deals" where "store_id" in (?, ?) and "is_active" = ? and ("expires_at" is null or "expires_at" >= ?) group by "store_id"
Bindings:
[646,142,true,"2026-09-08T05:06:01.772333Z"]