#1
⏱️ 57.53 мс
select "id" from "stores" where "is_active" = ? and "city_slug" = ?
Bindings:
[true,"bnei-brak"]
#2
⏱️ 1844.72 мс
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","baking_spices",730,748,288,45,80,135,163,432,477,502,682,84,86,217,265,282,285,298,true,730,748,288,45,80,135,163,432,477,502,682,84,86,217,265,282,285,298]
#3
⏱️ 1184.87 мс
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","baking_spices",730,748,288,45,80,135,163,432,477,502,682,84,86,217,265,282,285,298,true,730,748,288,45,80,135,163,432,477,502,682,84,86,217,265,282,285,298]
#4
⏱️ 10.23 мс
select * from "canonical_products" where "canonical_products"."id" in (64, 225)
#5
⏱️ 6.68 мс
select "id", "canonical_product_id" from "master_products" where "canonical_product_id" in (?, ?)
Bindings:
[64,225]
#6
⏱️ 425.23 мс
select * from "deals" where "master_product_id" in (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) and "is_active" = ? and "store_id" in (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)
Bindings:
[7518269,3230535,2842852,2702452,2680174,2670979,2666098,2666027,2663549,2640775,2640774,2608194,1959857,1908616,1908615,1474523,1472108,1469150,1465150,1457784,1455751,1455745,1455741,1455708,1455705,1455698,1455697,1451848,1451847,1451739,1451673,1433604,130435,100585,97793,true,730,748,288,45,80,135,163,432,477,502,682,84,86,217,265,282,285,298]
#7
⏱️ 10.42 мс
select * from "stores" where "stores"."id" in (84, 86, 135, 217, 265, 282, 285, 288, 298)
#8
⏱️ 19.45 мс
select min(sp.id) as best_sp_id from "store_prices" as "sp" where "sp"."master_product_id" in (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) and "sp"."price" > ? and "sp"."store_id" in (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) group by sp.store_id, CASE WHEN sp.master_product_id = 1465150 THEN 1465150 WHEN sp.master_product_id = 130435 THEN 1465150 WHEN sp.master_product_id = 1455697 THEN 1455697 WHEN sp.master_product_id = 100585 THEN 1455697 WHEN sp.master_product_id = 97793 THEN 1455697 ELSE sp.master_product_id END limit 500
Bindings:
[7518269,3230535,2842852,2702452,2680174,2670979,2666098,2666027,2663549,2640775,2640774,2608194,1959857,1908616,1908615,1474523,1472108,1469150,1465150,1457784,1455751,1455745,1455741,1455708,1455705,1455698,1455697,1451848,1451847,1451739,1451673,1433604,130435,100585,97793,0,730,748,288,45,80,135,163,432,477,502,682,84,86,217,265,282,285,298]
#9
⏱️ 58.07 мс
select * from "store_prices" where "id" in (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)
Bindings:
[4754840,4754906,4754907,4763659,4763661,4763680,4763684,4763687,4766393,4709677,4715913,4715915,4715919,4715923,4718438,4718442,4718446,4721593,5896381,6175661,4800225,5575352,5575379,5587821,5587823,5587831,5587853,5587857,5587862,5592203,5585891,5585202,5585203,5580540,654591,5485868,5485872,5485894,5485898,5485903,5491058,5485744,5483428,5483429,5237560,5237658,5247187,5247189,5247196,5247201,5247220,5247224,5247228,5254383,5247043,5244705,5244706,4904279,2052256,2045354,2046846,2045640,2045689,2048222,2049572,2053176,2047619,2043325,29420029,33192397,12019208,12019210,12026967,2510613,12016498,31651963,2511260,30366567,2602108,30364459,30364460,19027698,1705474,1705478,1705484,32868818,1701973,6748148,6758825,1698266,1698754,1703011,1705296,6748651,29096818,1702250,29088876]
#10
⏱️ 6.38 мс
select * from "stores" where "stores"."id" in (84, 86, 135, 217, 265, 282, 285, 288, 298, 432, 477, 502, 748)
#11
⏱️ 4.65 мс
select * from "locations" where "city_slug" = ? limit 1
Bindings:
["bnei-brak"]
#12
⏱️ 2.3 мс
select * from "locations" where "is_popular" = ? order by "sort_order" asc
Bindings:
[true]
#13
⏱️ 3.04 мс
select * from "locations" where "is_active" = ? order by "is_popular" desc, "sort_order" asc
Bindings:
[true]