I am connecting to a Microsoft Access via ODBC and I am connecting successfully. When I try to query a table using the SQL statement illustrated in my code I get no results even for values that are in the table. If I echo my query statement $q and put it in MS office IDE it gives me some results can anyone help?
[php]
$conn=ODBC_connect('Msc', 'user', 'password');
if ($conn)
{
$q = "
SELECT * FROM tblUsers WHERE UserName='$user' AND Pasword='$pword'";
$r = odbc_exec($conn,$q);
if (odbc_num_rows($r) == 1) {
return TRUE;
} else {
return FALSE;
}[/php]