#1
⏱️ 41.76 мс
select "id" from "stores" where "is_active" = ? and "city_slug" = ?
Bindings:
[true,"ramat-gan"]
#2
⏱️ 386.25 мс
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:
["drinks","soft_drinks",1109,30,760,264,108,1146,557,608,1283,1287,1288,1300,1339,1,367,41,53,54,301,539,555,580,679,1398,76,235,284,296,340,326,384,true,1109,30,760,264,108,1146,557,608,1283,1287,1288,1300,1339,1,367,41,53,54,301,539,555,580,679,1398,76,235,284,296,340,326,384]
#3
⏱️ 127.1 мс
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:
["drinks","soft_drinks",1109,30,760,264,108,1146,557,608,1283,1287,1288,1300,1339,1,367,41,53,54,301,539,555,580,679,1398,76,235,284,296,340,326,384,true,1109,30,760,264,108,1146,557,608,1283,1287,1288,1300,1339,1,367,41,53,54,301,539,555,580,679,1398,76,235,284,296,340,326,384]
#4
⏱️ 14.56 мс
select * from "deals" where "master_product_id" in (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) and "is_active" = ? and "store_id" in (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)
Bindings:
[78531197,30721319,28401773,13020236,12196436,4990596,4988535,4987774,4984993,4548104,4376775,4005453,3986522,3985360,3973339,3973338,3972211,3967178,2953027,2682071,2097960,1420356,1420349,545496,283120,246597,209042,193482,189152,189150,189149,188925,true,1109,30,760,264,108,1146,557,608,1283,1287,1288,1300,1339,1,367,41,53,54,301,539,555,580,679,1398,76,235,284,296,340,326,384]
#5
⏱️ 3.53 мс
select * from "stores" where "stores"."id" in (1, 30, 108, 235, 264, 296, 301, 326, 340, 367, 384)
#6
⏱️ 14.77 мс
select * from "store_prices" where "master_product_id" in (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) and "price" > ? and "store_id" in (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)
Bindings:
[78531197,30721319,28401773,13020236,12196436,4990596,4988535,4987774,4984993,4548104,4376775,4005453,3986522,3985360,3973339,3973338,3972211,3967178,2953027,2682071,2097960,1420356,1420349,545496,283120,246597,209042,193482,189152,189150,189149,188925,0,1109,30,760,264,108,1146,557,608,1283,1287,1288,1300,1339,1,367,41,53,54,301,539,555,580,679,1398,76,235,284,296,340,326,384]
#7
⏱️ 3.32 мс
select * from "stores" where "stores"."id" in (1, 235, 264, 301, 326, 340, 367, 384, 555, 557, 580, 608)
#8
⏱️ 1.32 мс
select * from "locations" where "city_slug" = ? limit 1
Bindings:
["ramat-gan"]
#9
⏱️ 1.15 мс
select * from "locations" where "is_popular" = ? order by "sort_order" asc
Bindings:
[true]
#10
⏱️ 1.59 мс
select * from "locations" where "is_active" = ? order by "is_popular" desc, "sort_order" asc
Bindings:
[true]