Searching Error [Solved]
Posted: Fri May 06, 2005 3:16 pm
I am using the query to search my database.
My problem is that when I search the database I get no results when I should. For example:
$sa = 149502930
$armysize = 1114
The defence of someone in the database is: 46372141
and their armysize: 31442
The query should search the database for anyone that has a defence action less then "149502930", and a armysize greater then "1114". Any suggestions?
Code: Select all
$query = mysql_query("SELECT * FROM `farms`
WHERE defence < '$sa'
AND armysize > '$armysize'
ORDER BY `time` ASC") or die(mysql_error());My problem is that when I search the database I get no results when I should. For example:
$sa = 149502930
$armysize = 1114
The defence of someone in the database is: 46372141
and their armysize: 31442
The query should search the database for anyone that has a defence action less then "149502930", and a armysize greater then "1114". Any suggestions?