#1
⏱️ 133.16 мс
select "id" from "stores" where "is_active" = ? and "city_slug" = ?
Bindings:
[true,"modiin"]
#2
⏱️ 454.08 мс
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:
["appliances","kitchen_appliances",713,763,111,345,1153,1201,1255,1273,40,426,439,549,406,147,305,348,true,713,763,111,345,1153,1201,1255,1273,40,426,439,549,406,147,305,348]
#3
⏱️ 364.46 мс
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:
["appliances","kitchen_appliances",713,763,111,345,1153,1201,1255,1273,40,426,439,549,406,147,305,348,true,713,763,111,345,1153,1201,1255,1273,40,426,439,549,406,147,305,348]
#4
⏱️ 13.03 мс
select * from "canonical_products" where "canonical_products"."id" in (25)
#5
⏱️ 7.53 мс
select "id", "canonical_product_id" from "master_products" where "canonical_product_id" in (?)
Bindings:
[25]
#6
⏱️ 30.9 мс
select * from "deals" where "master_product_id" in (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) and "is_active" = ? and "store_id" in (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)
Bindings:
[4574975,4013398,3362845,2816262,2782222,2708626,2707089,2702790,2685471,2676233,2675929,2671430,2670760,2670268,2664339,2663976,2662602,2662458,2662434,2661254,2657025,2641224,2638261,2636108,907294,207687,207685,199186,199076,198135,198134,197313,2657391,2702341,true,713,763,111,345,1153,1201,1255,1273,40,426,439,549,406,147,305,348]
#7
⏱️ 11.59 мс
select * from "stores" where "stores"."id" in (406)
#8
⏱️ 27.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 = 2676233 THEN 2657025 WHEN sp.master_product_id = 2657391 THEN 2657025 WHEN sp.master_product_id = 2657025 THEN 2657025 WHEN sp.master_product_id = 2702341 THEN 2657025 ELSE sp.master_product_id END limit 500
Bindings:
[4574975,4013398,3362845,2816262,2782222,2708626,2707089,2702790,2685471,2676233,2675929,2671430,2670760,2670268,2664339,2663976,2662602,2662458,2662434,2661254,2657025,2641224,2638261,2636108,907294,207687,207685,199186,199076,198135,198134,197313,2657391,2702341,0,713,763,111,345,1153,1201,1255,1273,40,426,439,549,406,147,305,348]
#9
⏱️ 37.65 мс
select * from "store_prices" where "id" in (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)
Bindings:
[1895421,1886543,10399057,1889262,1892288,1896755,1896865,1898370,10410007,1886546,1897596,1895431,29280861,1892789,33054583,10409352,1897178,1886545,1892772,10787273,2138595,2148172,2138109,10780418,10787429,2146846,2146851,2146717,31174600,2138615,29520466,29523174,2149785,2152504,29514236,29520353,10790355,2138613,29527810,31172653,24711644,3096602,2731047,2731048,2732068,2732166,2729463,2729465,39591781]
#10
⏱️ 9.11 мс
select * from "stores" where "stores"."id" in (426, 439, 549, 713)
#11
⏱️ 12.22 мс
select * from "locations" where "city_slug" = ? limit 1
Bindings:
["modiin"]
#12
⏱️ 7.8 мс
select * from "locations" where "is_popular" = ? order by "sort_order" asc
Bindings:
[true]
#13
⏱️ 13.01 мс
select * from "locations" where "is_active" = ? order by "is_popular" desc, "sort_order" asc
Bindings:
[true]