#1
⏱️ 121.48 мс
select "id" from "stores" where "is_active" = ? and "city_slug" = ?
Bindings:
[true,"ramat-gan"]
#2
⏱️ 1051.37 мс
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:
["pharmacy","cosmetics_beauty",1109,760,340,384,284,296,1146,557,608,1283,1287,1288,1300,1339,1,326,367,30,41,53,54,76,108,235,264,301,539,555,580,679,1398,true,1109,760,340,384,284,296,1146,557,608,1283,1287,1288,1300,1339,1,326,367,30,41,53,54,76,108,235,264,301,539,555,580,679,1398]
#3
⏱️ 686.33 мс
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:
["pharmacy","cosmetics_beauty",1109,760,340,384,284,296,1146,557,608,1283,1287,1288,1300,1339,1,326,367,30,41,53,54,76,108,235,264,301,539,555,580,679,1398,true,1109,760,340,384,284,296,1146,557,608,1283,1287,1288,1300,1339,1,326,367,30,41,53,54,76,108,235,264,301,539,555,580,679,1398]
#4
⏱️ 126.55 мс
select * from "deals" where "master_product_id" in (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) and "is_active" = ? and "store_id" in (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)
Bindings:
[4095651,4073345,4073344,4073343,4068252,4067969,4067541,4065749,4062070,4039491,4033597,4000631,3934963,3934962,2111996,1846388,1772053,1704568,1644119,1641216,1618695,1616791,1616789,1616267,1613566,1612127,1609516,1560460,1560353,1560345,1559544,1559432,true,1109,760,340,384,284,296,1146,557,608,1283,1287,1288,1300,1339,1,326,367,30,41,53,54,76,108,235,264,301,539,555,580,679,1398]
#5
⏱️ 10.42 мс
select * from "stores" where "stores"."id" in (1, 235, 264)
#6
⏱️ 21.97 мс
select * from "store_prices" where "master_product_id" in (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) and "price" > ? and "store_id" in (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)
Bindings:
[4095651,4073345,4073344,4073343,4068252,4067969,4067541,4065749,4062070,4039491,4033597,4000631,3934963,3934962,2111996,1846388,1772053,1704568,1644119,1641216,1618695,1616791,1616789,1616267,1613566,1612127,1609516,1560460,1560353,1560345,1559544,1559432,0,1109,760,340,384,284,296,1146,557,608,1283,1287,1288,1300,1339,1,326,367,30,41,53,54,76,108,235,264,301,539,555,580,679,1398]
#7
⏱️ 8.78 мс
select * from "stores" where "stores"."id" in (235, 557)
#8
⏱️ 9.81 мс
select * from "locations" where "city_slug" = ? limit 1
Bindings:
["ramat-gan"]
#9
⏱️ 15.67 мс
select * from "locations" where "is_popular" = ? order by "sort_order" asc
Bindings:
[true]
#10
⏱️ 13.03 мс
select * from "locations" where "is_active" = ? order by "is_popular" desc, "sort_order" asc
Bindings:
[true]