I'm working on a real estate search form. The user can select any number of areas in which to search (from a multiple selection box) as well as define other search parameters like price, sq ft, etc. The query works if I either remove the Area portion or remove everything but the Area portion. As the query is now, the results are correct for all of the search parameters except the Area array with is completely ignored. I know the values for the array are being passed to the query because I can echo the array variable and the correct array is returned.
Here's the query:
What am I missing?Code:SELECT * FROM ListingsResidential WHERE 1=1 OR Area IN (choosearea) // allows for NO selection AND Price BETWEEN pricemin and pricemax AND Beds >= bed AND FullBaths >= bath AND SqFt >= sqftmin ORDER BY Price ASC







Bookmarks