php and mysql query
Hai
In my application I am using one query like this
$qry_count ="SELECT COUNT(*) FROM tbl_mail LEFT JOIN tbl_country ON tbl_mail.country_id = tbl_country.country_id WHERE tbl_mail.deleted_status <> 'Y' AND tbl_mail.first_name LIKE '%x%'";
This query work fine in my php application and mysqladmin.
But if I tried using
$qry_count ="SELECT COUNT(*) FROM tbl_mail LEFT JOIN tbl_country ON tbl_mail.country_id = tbl_country.country_id WHERE tbl_mail.deleted_status <> 'Y' AND tbl_mail.first_name LIKE '%xxxxxx%'";
Here I am getting following error in php but it work fine in Mysqladmin.
You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '-10,10' at line 1.
Any body have idea on this
Thanks!:)
|