#2
⏱️ 764.68 мс
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",90,471,243,true,90,471,243]
#3
⏱️ 704.57 мс
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",90,471,243,true,90,471,243]
#4
⏱️ 10.09 мс
select * from "deals" where "master_product_id" in (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) and "is_active" = ? and "store_id" in (?, ?, ?)
Bindings:
[1919767,1911874,1910173,1909366,1831786,1611230,1559519,1546573,1543653,1543532,1543531,1543418,1543398,1543379,1543275,1538948,1531752,1531746,1518867,1515569,1515506,1508463,1507474,1507411,1507326,1506487,1503576,1503418,1502751,1499012,1498034,1498021,true,90,471,243]
#6
⏱️ 14.64 мс
select * from "store_prices" where "master_product_id" in (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) and "price" > ? and "store_id" in (?, ?, ?)
Bindings:
[1919767,1911874,1910173,1909366,1831786,1611230,1559519,1546573,1543653,1543532,1543531,1543418,1543398,1543379,1543275,1538948,1531752,1531746,1518867,1515569,1515506,1508463,1507474,1507411,1507326,1506487,1503576,1503418,1502751,1499012,1498034,1498021,0,90,471,243]
#9
⏱️ 88.77 мс
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:
[90,471,243,true,"2026-09-08T05:00:18.732971Z"]