#1
⏱️ 148.9 мс
select "id" from "stores" where "is_active" = ? and "city_slug" = ?
Bindings:
[true,"nahariya"]
#2
⏱️ 2151.36 мс
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","sauces_oils",766,1123,1254,446,1362,10,241,410,true,766,1123,1254,446,1362,10,241,410]
#3
⏱️ 763.03 мс
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","sauces_oils",766,1123,1254,446,1362,10,241,410,true,766,1123,1254,446,1362,10,241,410]
#4
⏱️ 7.39 мс
select * from "canonical_products" where "canonical_products"."id" in (264)
#5
⏱️ 6.16 мс
select "id", "canonical_product_id" from "master_products" where "canonical_product_id" in (?)
Bindings:
[264]
#6
⏱️ 14.63 мс
select * from "deals" where "master_product_id" in (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) and "is_active" = ? and "store_id" in (?, ?, ?, ?, ?, ?, ?, ?)
Bindings:
[75165094,30691571,25603232,3931378,3484014,2811192,2807243,2752605,2702263,2671353,2669776,2658241,2657764,2632495,2631542,1972068,1546573,1507326,1486122,1482065,1478581,1476182,1475502,1474452,1458529,1458528,1458526,1456529,1438422,1437983,1435632,1434614,98914,true,766,1123,1254,446,1362,10,241,410]
#7
⏱️ 4.46 мс
select * from "stores" where "stores"."id" in (10, 241, 410)
#8
⏱️ 11.93 мс
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 = 98914 THEN 1458529 WHEN sp.master_product_id = 1458529 THEN 1458529 ELSE sp.master_product_id END limit 500
Bindings:
[75165094,30691571,25603232,3931378,3484014,2811192,2807243,2752605,2702263,2671353,2669776,2658241,2657764,2632495,2631542,1972068,1546573,1507326,1486122,1482065,1478581,1476182,1475502,1474452,1458529,1458528,1458526,1456529,1438422,1437983,1435632,1434614,98914,0,766,1123,1254,446,1362,10,241,410]
#9
⏱️ 22.91 мс
select * from "store_prices" where "id" in (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)
Bindings:
[817123,5619597,5604338,5614291,5618096,925761,5618595,5601870,5614102,5608918,5606705,1505825,67876284,2225587,2226096,2233957,39152722,2227569,29607653,29624466,2225184,2237573,2229962,2225885,2236287,11008593,10979567,11001034,46780664,71688162]
#10
⏱️ 12.58 мс
select * from "stores" where "stores"."id" in (10, 241, 410, 446)
#11
⏱️ 3.34 мс
select * from "locations" where "city_slug" = ? limit 1
Bindings:
["nahariya"]
#12
⏱️ 6.11 мс
select * from "locations" where "is_popular" = ? order by "sort_order" asc
Bindings:
[true]
#13
⏱️ 9.1 мс
select * from "locations" where "is_active" = ? order by "is_popular" desc, "sort_order" asc
Bindings:
[true]