If I enter this query at the sql prompt, I'll get results, but the code at the end of this yields the following error:
Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result resource in...on line 104
$query = "SELECT * FROM activity, customers WHERE activity.UserID=customers.UID AND (month(thisDateField) = month(now()) and dayofmonth(thisDateField) = (dayofmonth(now())-1) and year(thisDateField)=year(now())) ORDER BY
activity.thisDateField";
$result = mysql_query ($query);
while ($row = mysql_fetch_array ($result, MYSQL_ASSOC)) { // This being Line 104
Can someone shed some light?