#1
⏱️ 213.8 мс
select "id" from "stores" where "is_active" = ? and "city_slug" = ?
Bindings:
[true,"karmiel"]
#2
⏱️ 669.48 мс
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","canned_preserves",743,119,1241,545,1325,398,29,98,186,450,684,true,743,119,1241,545,1325,398,29,98,186,450,684]
#3
⏱️ 496.52 мс
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","canned_preserves",743,119,1241,545,1325,398,29,98,186,450,684,true,743,119,1241,545,1325,398,29,98,186,450,684]
#4
⏱️ 7.75 мс
select * from "deals" where "master_product_id" in (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) and "is_active" = ? and "store_id" in (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)
Bindings:
[4038041,1426265,452321,409610,314345,314342,314340,314335,314334,314331,314329,314328,314326,196266,183236,183235,180574,180573,174683,173793,171843,168430,168428,168427,168424,168210,168209,167775,159709,157600,156219,155852,true,743,119,1241,545,1325,398,29,98,186,450,684]
#5
⏱️ 1.05 мс
select * from "stores" where "stores"."id" in (29, 98, 398)
#6
⏱️ 10.77 мс
select * from "store_prices" where "master_product_id" in (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) and "price" > ? and "store_id" in (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)
Bindings:
[4038041,1426265,452321,409610,314345,314342,314340,314335,314334,314331,314329,314328,314326,196266,183236,183235,180574,180573,174683,173793,171843,168430,168428,168427,168424,168210,168209,167775,159709,157600,156219,155852,0,743,119,1241,545,1325,398,29,98,186,450,684]
#7
⏱️ 3.57 мс
select * from "stores" where "stores"."id" in (29, 98, 398, 450, 545)
#8
⏱️ 3.66 мс
select * from "locations" where "city_slug" = ? limit 1
Bindings:
["karmiel"]
#9
⏱️ 5.42 мс
select * from "locations" where "is_popular" = ? order by "sort_order" asc
Bindings:
[true]
#10
⏱️ 5.82 мс
select * from "locations" where "is_active" = ? order by "is_popular" desc, "sort_order" asc
Bindings:
[true]