#1
⏱️ 130.32 мс
select "id" from "stores" where "is_active" = ? and "city_slug" = ?
Bindings:
[true,"beer-sheva"]
#2
⏱️ 1036.32 мс
select count(*) as "aggregate" from "master_products" where "barcode" is not null and "category_slug" = ? and "master_products"."id" in ((select "master_product_id" from "store_prices" where "store_id" in (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)) union (select "master_product_id" from "deals" where "is_active" = ? and "store_id" in (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)))
Bindings:
["appliances",736,754,776,132,172,246,1169,1170,1206,1249,1271,1274,1279,1299,1307,369,44,93,113,120,160,151,164,165,181,271,441,465,473,490,1370,1400,350,true,736,754,776,132,172,246,1169,1170,1206,1249,1271,1274,1279,1299,1307,369,44,93,113,120,160,151,164,165,181,271,441,465,473,490,1370,1400,350]
#3
⏱️ 840.03 мс
select * from "master_products" where "barcode" is not null and "category_slug" = ? and "master_products"."id" in ((select "master_product_id" from "store_prices" where "store_id" in (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)) union (select "master_product_id" from "deals" where "is_active" = ? and "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",736,754,776,132,172,246,1169,1170,1206,1249,1271,1274,1279,1299,1307,369,44,93,113,120,160,151,164,165,181,271,441,465,473,490,1370,1400,350,true,736,754,776,132,172,246,1169,1170,1206,1249,1271,1274,1279,1299,1307,369,44,93,113,120,160,151,164,165,181,271,441,465,473,490,1370,1400,350]
#4
⏱️ 15.67 мс
select * from "canonical_products" where "canonical_products"."id" in (25)
#5
⏱️ 10.69 мс
select "id", "canonical_product_id" from "master_products" where "canonical_product_id" in (?)
Bindings:
[25]
#6
⏱️ 255.81 мс
select * from "deals" where "master_product_id" in (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) and "is_active" = ? and "store_id" in (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)
Bindings:
[8775816,8775815,8775810,8775804,8775803,8775802,8775801,8775755,3875956,3875872,2707089,2702790,2670268,2657025,2641224,2636108,1429426,1429424,249788,244506,123088,115120,101406,98575,98574,8775817,8775750,8775749,8775747,8775738,7443046,4536413,2657391,2676233,2702341,true,736,754,776,132,172,246,1169,1170,1206,1249,1271,1274,1279,1299,1307,369,44,93,113,120,160,151,164,165,181,271,441,465,473,490,1370,1400,350]
#7
⏱️ 11.1 мс
select * from "stores" where "stores"."id" in (93, 113, 120, 132, 151, 172, 181, 246, 271, 350, 369, 736, 776)
#8
⏱️ 25.13 мс
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 = 2657391 THEN 2657025 WHEN sp.master_product_id = 2657025 THEN 2657025 WHEN sp.master_product_id = 2676233 THEN 2657025 WHEN sp.master_product_id = 2702341 THEN 2657025 ELSE sp.master_product_id END limit 500
Bindings:
[8775816,8775815,8775810,8775804,8775803,8775802,8775801,8775755,3875956,3875872,2707089,2702790,2670268,2657025,2641224,2636108,1429426,1429424,249788,244506,123088,115120,101406,98575,98574,8775817,8775750,8775749,8775747,8775738,7443046,4536413,2657391,2676233,2702341,0,736,754,776,132,172,246,1169,1170,1206,1249,1271,1274,1279,1299,1307,369,44,93,113,120,160,151,164,165,181,271,441,465,473,490,1370,1400,350]
#9
⏱️ 27.46 мс
select * from "store_prices" where "id" in (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)
Bindings:
[4622329,4622330,4622340,6525671,6525672,6436599,6436600,6440205,6436610,537581,537582,539068,537592,4905505,4905506,4905515,872033,872034,873584,872044,4746548,4746549,4748794,4748797,606538,606539,609324,607974,5324878,5215507,5215508,5217795,5217798,1131406,1131407,5289390,1131417,1194956,1194957,6040959,1194967,2166954,2172277,2175561,2167584,2171194,2172703,2437665,2438872,2437383,2437418,2491784,4006345,4027888,4026125,4026340,4026383,4026426,4026469,4027630,4027673,4027716,4027759,4027931,4028017,4028060,4028318,1782678,1780536,1787645,1789355,1778080,1781162]
#10
⏱️ 8.92 мс
select * from "stores" where "stores"."id" in (93, 113, 120, 132, 151, 172, 181, 246, 271, 350, 369, 441, 465, 473, 736, 754)
#11
⏱️ 5.62 мс
select * from "locations" where "city_slug" = ? limit 1
Bindings:
["beer-sheva"]
#12
⏱️ 8.02 мс
select * from "locations" where "is_popular" = ? order by "sort_order" asc
Bindings:
[true]
#13
⏱️ 9.43 мс
select * from "locations" where "is_active" = ? order by "is_popular" desc, "sort_order" asc
Bindings:
[true]