When I try to run the following query:
$strSQL = mysql_query("SELECT *, MIN (price)
FROM products, products_pricing
WHERE catID='$catID' AND
subcatID='$subcatID' AND
products.item_num = products_pricing.item_num
GROUP BY products_pricing.item_num
ORDER BY price", $conn) or die(mysql_error());
I get this reply in my browser:
FUNCTION pp.MIN does not exist
(pp refers to my table)
When I run the same query (of course, without variables) in the MYSQL command line client, it works fine.
Why is this happening?