Jump to content

Quick help!


hybmg57

Recommended Posts

Is there anything wrong with below code? It was working fine 2 hours ago but after a few changes it's not retrieving data anymore it's just giving the entire data without filtering... Any ideas???

 

$result = mysql_query("SELECT * 
					FROM residential 
					WHERE	PROPSUBTYPEDISPLAY LIKE '%{$Property_Type}%'
					AND	AREA {$Any_City} {$City}
					AND	BEDS >={$Beds}
					AND	BATHSTOTAL >={$Baths}
					AND	LISTPRICE >={$Lowest_Price}
					AND	LISTPRICE {$Any} {$Highest_Price}
					AND	CITY LIKE '%{$CityA}%'
					AND STREETNAME LIKE '%{$AddressA}%'
					AND ZIPCODE {$Any_Zip} '{$Zip_codeA}'
					AND SUBDIVISION LIKE '%{$SubdivisionA}%'
					AND GARAGECAP	>=	{$GarageA}
					AND STORIES		>=	{$StoriesA}
					AND	FIREPLACES	>=	{$FireplacesA}
					AND LOTSIZE		{$Yard}
					AND SCHOOLDISTRICT LIKE '%{$School_districtA}%'
					AND SCHOOLNAME1 LIKE '%{$School_nameA}%'
					AND SCHOOLNAME2 LIKE '%{$School_nameA}%'
					AND SCHOOLNAME3 LIKE '%{$School_nameA}%'
					AND SCHOOLTYPE1 {$E}
					AND SCHOOLTYPE2 {$M}
					AND SCHOOLTYPE3 {$H}
					AND EXTERIOR 	{$Guest_quartersA}
					AND HOUSINGTYPE {$High_riseA}
					AND INTERIOR	{$Loft_A}
					AND EXTERIOR	{$BalconyA}
					AND ROOMOTHER	{$LibraryA}
					AND ROOMOTHER	{$MediaA}
					AND COMMONFEATURES	{$Gated_communityA}
					AND COMMONFEATURES	{$Golf_course_communityA}
					AND COMMONFEATURES	{$Golf_course_lotA}
					AND COMMONFEATURES	{$Lake_front_lotA}
					AND COMMONFEATURES	{$Lake_viewA}
					{$CitiesA0}
					{$CitiesA1}
					{$CitiesA2}
					{$CitiesA3}
					{$CitiesA4}
					{$CitiesA5}
					{$CitiesA6}
					{$CitiesA7}
					{$CitiesA8}
					{$CitiesA9}
					{$CitiesA10}
					{$AreasA0}
					{$AreasA1}
					{$AreasA2}
					{$AreasA3}
					{$AreasA4}
					{$AreasA5}
					{$AreasA6}
					{$AreasA7}
					{$AreasA8}
					{$AreasA9}
					{$AreasA10}
					{$CountiesA0}
					{$CountiesA1}
					{$CountiesA2}
					{$CountiesA3}
					{$CountiesA4}
					{$CountiesA5}
					{$CountiesA6}
					{$CountiesA7}
					{$CountiesA8}
					{$CountiesA9}
					{$CountiesA10}


					AND PHOTOCOUNT	{$Properties_with_photosA}

					ORDER BY {$sort}
					LIMIT {$offset}, {$limit}")
or die(mysql_error());

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.