#1
⏱️ 217.69 мс
select "id" from "stores" where "is_active" = ? and "city_slug" = ?
Bindings:
[true,"holon"]
#2
⏱️ 3159 мс
select count(*) as "aggregate" from "master_products" where "barcode" is not null and "category_slug" = ? and "subcategory_slug" = ? and (exists (select 1 from "store_prices" where "store_prices"."master_product_id" = "master_products"."id" and "store_prices"."store_id" in (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)) or exists (select 1 from "deals" where "deals"."master_product_id" = "master_products"."id" and "deals"."is_active" = ? and "deals"."store_id" in (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)))
Bindings:
["grocery","sauces_oils",1114,234,752,1168,1216,1327,167,528,463,497,552,573,665,678,1411,23,145,253,360,true,1114,234,752,1168,1216,1327,167,528,463,497,552,573,665,678,1411,23,145,253,360]
#3
⏱️ 2572.35 мс
select * from "master_products" where "barcode" is not null and "category_slug" = ? and "subcategory_slug" = ? and (exists (select 1 from "store_prices" where "store_prices"."master_product_id" = "master_products"."id" and "store_prices"."store_id" in (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)) or exists (select 1 from "deals" where "deals"."master_product_id" = "master_products"."id" and "deals"."is_active" = ? and "deals"."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","sauces_oils",1114,234,752,1168,1216,1327,167,528,463,497,552,573,665,678,1411,23,145,253,360,true,1114,234,752,1168,1216,1327,167,528,463,497,552,573,665,678,1411,23,145,253,360]
#4
⏱️ 16.67 мс
select * from "deals" where "master_product_id" in (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) and "is_active" = ? and "store_id" in (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)
Bindings:
[117041541,117041540,75165094,66413048,30691571,27628022,25603232,8775770,8616048,7495251,4165706,4160642,4159848,4146399,4135281,4125284,4085362,4073345,4066766,4055659,4053175,4016529,4015098,4005817,4004074,4003862,4003598,4002660,3991692,3985594,3985590,3984306,true,1114,234,752,1168,1216,1327,167,528,463,497,552,573,665,678,1411,23,145,253,360]
#5
⏱️ 12.4 мс
select * from "stores" where "stores"."id" in (234, 253, 528)
#6
⏱️ 19.95 мс
select * from "store_prices" where "master_product_id" in (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) and "price" > ? and "store_id" in (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)
Bindings:
[117041541,117041540,75165094,66413048,30691571,27628022,25603232,8775770,8616048,7495251,4165706,4160642,4159848,4146399,4135281,4125284,4085362,4073345,4066766,4055659,4053175,4016529,4015098,4005817,4004074,4003862,4003598,4002660,3991692,3985594,3985590,3984306,0,1114,234,752,1168,1216,1327,167,528,463,497,552,573,665,678,1411,23,145,253,360]
#7
⏱️ 11.14 мс
select * from "stores" where "stores"."id" in (253, 463, 497, 528, 552, 573, 752)
#8
⏱️ 8.03 мс
select * from "locations" where "city_slug" = ? limit 1
Bindings:
["holon"]
#9
⏱️ 14.95 мс
select * from "locations" where "is_popular" = ? order by "sort_order" asc
Bindings:
[true]
#10
⏱️ 16.65 мс
select * from "locations" where "is_active" = ? order by "is_popular" desc, "sort_order" asc
Bindings:
[true]