Using module version 1.12 through 1.17, Drupal 5.1, PHP 5.1.6, mysql 5.0.19:

I get the following error when I click on mailing lists tab in user profile

user warning: 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 'WHERE address = 'color.art@mac.com' LIMIT 1' at line 2 query: SELECT 1 FROM WHERE address = 'color.art@mac.com' LIMIT 1 in /Applications/MAMP/htdocs/includes/database.mysql.inc on line 172.

Trying to subscribe to a mailing list gets the following

* user warning: 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 'WHERE address = 'color.art@mac.com' LIMIT 1' at line 2 query: SELECT 1 FROM WHERE address = 'color.art@mac.com' LIMIT 1 in /Applications/MAMP/htdocs/includes/database.mysql.inc on line 172.
* user warning: 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 'WHERE address = 'color.art@mac.com' LIMIT 1' at line 2 query: SELECT 1 FROM WHERE address = 'color.art@mac.com' LIMIT 1 in /Applications/MAMP/htdocs/includes/database.mysql.inc on line 172.
* user warning: 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 'WHERE address = 'color.art@mac.com'' at line 1 query: SELECT 1 FROM WHERE address = 'color.art@mac.com' in /Applications/MAMP/htdocs/includes/database.mysql.inc on line 172.
* user warning: 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 '( hash, address ) VALUES ( '40', 'color.art@mac.com' )' at line 1 query: INSERT INTO ( hash, address ) VALUES ( '40', 'color.art@mac.com' ) in /Applications/MAMP/htdocs/includes/database.mysql.inc on line 172.
* user warning: Table 'wildbase._slog' doesn't exist query: INSERT INTO _slog ( tai, address, fromline, edir) VALUES ( '2007-07-26 09:53:25', 'color.art@mac.com', 'color.art@mac.com', '+') in /Applications/MAMP/htdocs/includes/database.mysql.inc on line 172.

Comments

jerdavis’s picture

Status: Active » Fixed

Some changes were just committed to HEAD which may fix this, also a new development version was generated which should show up shortly. If you can still reproduce the behavior above with this version please let us know.

Anonymous’s picture

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for two weeks with no activity.

kwamecg’s picture

Title: Error in SQL sytax » You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to us

$wball=mysql_query("SELECT * FROM node_revisions,term_node where node_revisions.vid=term_node.vid AND term_node.tid=3 ORDER BY timestamp DESC limit 6");

this is the query that is giving me the error....

HEROESgifted’s picture

How do I fix this error message?

user warning: 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 ' events.field_date_value FROM node n INNER JOIN signup s ON s.nid = n.nid LEFT J' at line 1 query: SELECT n.nid, n.title, n.type, s.status AS signup_status, COUNT(s_l.nid) AS signup_total, s.close_signup_limit AS signup_close_signup_limit, courses.field_date_value, date., events.field_date_value FROM node n INNER JOIN signup s ON s.nid = n.nid LEFT JOIN signup_log s_l ON s.nid = s_l.nid LEFT JOIN content_field_date `courses` ON courses.vid = n.vid LEFT JOIN `date` ON date.vid = n.vid LEFT JOIN content_field_date `events` ON events.vid = n.vid GROUP BY n.nid, n.title, signup_status, signup_close_signup_limit ORDER BY n.title ASC LIMIT 0, 25 in /home2/heroesgi/public_html/modules/signup/signup/includes/admin.signup_administration.inc on line 76.

milziv’s picture

Hi there,

I have the same error message...any workaround for this issue? Much appreicated.

user warning: 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 '= 424 ) count_alias' at line 3nquery: SELECT COUNT(*) FROM (SELECT send.sid AS sid FROM send send WHERE .nid = 424 ) count_alias in /www/itsmforg/itsmfSerbia/docroot/drupal/sites/all/modules/views/includes/view.inc on line 745.

user warning: 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 '= 424 LIMIT 0, 20' at line 8nquery: SELECT send.sid AS sid, send.timestamp AS send_timestamp, name, uid, send.subject AS send_subject, send.message AS send_message FROM send send WHERE .nid = 424 LIMIT 0, 20 in /www/itsmforg/itsmfSerbia/docroot/drupal/sites/all/modules/views/includes/view.inc on line 771.

Thanks

tryitonce’s picture

I have something very similar - did you find a solution?
I have:

    * user warning: 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 '<> 0 OR (.uid = 1 AND 1 <> 0) OR 1 = 1 ) count_alias' at line 3 query: SELECT COUNT(*) FROM (SELECT comments.cid AS cid FROM comments comments WHERE .status <> 0 OR (.uid = 1 AND 1 <> 0) OR 1 = 1 ) count_alias in /home/ .......  /public_html/sites/all/modules/views/includes/view.inc on line 745.
    * user warning: 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 '<> 0 OR (.uid = 1 AND 1 <> 0) OR 1 = 1 ORDER BY comments_timestamp DESC LIMI' at line 9 query: SELECT comments.cid AS cid, comments.subject AS comments_subject, comments.nid AS comments_nid, comments.timestamp AS comments_timestamp, comments.name AS comments_name, comments.uid AS comments_uid, comments.homepage AS comments_homepage FROM comments comments WHERE .status <> 0 OR (.uid = 1 AND 1 <> 0) OR 1 = 1 ORDER BY comments_timestamp DESC LIMIT 0, 5 in /home/ ......    /public_html/sites/all/modules/views/includes/view.inc on line 771.

thanks .....