The following SQL error is generated if:

  • image vocabulary is not set to 'required' and
  • an image is previewed or submitted with no taxonomy term selected and personal gallery is set to 'disabled'
user error: 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 'ORDER BY n.title' at line 6
query: 
          SELECT n.nid, n.title, n.teaser, n.body, i.thumb_path
          FROM node n, term_node t, image i
          WHERE n.nid = t.nid
          AND n.nid = i.nid
          AND i.personal = 0
          AND t.tid =  ORDER BY n.title in d:\htdocs\tests\drupal-4.2.0\includes\database.mysql.inc on line 79.

Comments

bruno’s picture

Fixed SQL query/PHP syntax to avoid empty argument to "t.tid =" causing error.

Same bug exits in HEAD and will be fixed as well.

Bruno

Anonymous’s picture