I'm using an ODBC for MS Access.
(I know Mysql is better, but the client wants
MS Access :-(
Now, the problem is that I created a search form that will allow a user to choose between two conditions:
<select name="minimum">
<option value=http://www.phpbuilder.com/board/archive/index.php/"0">No Minimum</option>
<option value="100000">$100,000</option>
<option value="200000">$200,000</option>
</select>
<select name="maximum">
<option value="100001">$100,001</option>
<option value="200001">$200,001</option>
<option value="8000000">No Maximum</option>
</select>
The SQL Query:
$sql=odbc_exec( $con, "SELECT * FROM tablename WHERE value >='$minimum' AND value <= '$maximum'");
The problem is ANY Value UNDER 100000
does not show up in my SELECT statement.
If I try a Minimum of Ex. 100000 and
No Maximum, all the houses but for the
houses below 100000 will show up.
A SELECT * FROM tablename
And listing ALL the houses, everything is fine. I've also tried BETWEEN/AND same
thing.
I've also tried the value=http://www.phpbuilder.com/board/archive/index.php/"0" to "000001",
just about any low number.
P.S. there are NO commas or Dollar signs that
may'confuse' the query results.
Any ideas would be GREATFULLY appreciated!!
Thanks!
BjM-
(I know Mysql is better, but the client wants
MS Access :-(
Now, the problem is that I created a search form that will allow a user to choose between two conditions:
<select name="minimum">
<option value=http://www.phpbuilder.com/board/archive/index.php/"0">No Minimum</option>
<option value="100000">$100,000</option>
<option value="200000">$200,000</option>
</select>
<select name="maximum">
<option value="100001">$100,001</option>
<option value="200001">$200,001</option>
<option value="8000000">No Maximum</option>
</select>
The SQL Query:
$sql=odbc_exec( $con, "SELECT * FROM tablename WHERE value >='$minimum' AND value <= '$maximum'");
The problem is ANY Value UNDER 100000
does not show up in my SELECT statement.
If I try a Minimum of Ex. 100000 and
No Maximum, all the houses but for the
houses below 100000 will show up.
A SELECT * FROM tablename
And listing ALL the houses, everything is fine. I've also tried BETWEEN/AND same
thing.
I've also tried the value=http://www.phpbuilder.com/board/archive/index.php/"0" to "000001",
just about any low number.
P.S. there are NO commas or Dollar signs that
may'confuse' the query results.
Any ideas would be GREATFULLY appreciated!!
Thanks!
BjM-