昨日完全に実行されているクエリがあり、その質問の Shaikh Farooque Linkによって回答されました
ここで、同じcuisine_idの下にあるfoodjoint_idの詳細をフィルタリングする必要がある別の問題があります。 ユーザーが緯度経度と料理 ID を送信しようとしている場合、それらの FoodJoint をフィルター処理する必要があります
私が言ったように、私はすでに実行中の Lat Long で Food Joint を検索しています。料理フィルターを追加する必要があります。
実行中のクエリは
SELECT foodjoint_id,foodjoint_name,open_hours,cont_no,address_line,city,
( 3959 * acos( cos( radians('".$userLatitude."') ) *
cos( radians( foodjoint_latitude) ) * cos( radians( foodjoint_longitude) -
radians('".$userLongitude."') ) + sin( radians('".$userLatitude."') ) *
sin( radians( foodjoint_latitude) ) ) ) AS distance,
(SELECT AVG(customer_ratings)
FROM customer_review
WHERE foodjoint_id=provider_food_joints.foodjoint_id) AS customer_rating
FROM provider_food_joints
HAVING distance < '3' ORDER BY distance
そして私はそれを追加しました:
SELECT foodjoint_id FROM menu_item WHERE cuisine_id=''.$userGivenCuisineId.''
問題はまだ解決されていないと言って申し訳ありません