Page 1 of 1

Invalid Query?

Posted: Sun Apr 15, 2007 8:33 am
by malcolmboston

Code: Select all

SELECT *
FROM `products`
WHERE `productCategoryID` = '1'
AND `productOnline` = '1'
ORDER BY `productCategoryID` DESC 
Error Reporting wrote: 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 'AND `productOnline` = 1' at line 4
Works in PHPmyAdmin, wont work in PHP, any ideas :cry:

Posted: Sun Apr 15, 2007 9:14 am
by Oren
Works for me with both.

Posted: Sun Apr 15, 2007 8:17 pm
by aaronhall
Have you echoed the query from PHP?