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 '( tn.tid SEPARATOR ',' ) AS tids FROM l query: SELECT li.nid, GROUP_CONCAT( tn.tid SEPARATOR ',' ) AS tids FROM leech_news_item li LEFT JOIN term_node tn ON tn.nid = li.nid WHERE li.fid = 0 GROUP BY nid in /home/www/doc/11111/mysite.com/www/includes/database.mysql.inc on line 121.
Sometimes when I add a new feed I get this. What could it be? (Drupal 4.7.5, fresh install)
Comments
Comment #1
aron novakWhich version of MySQL do you use?
Can you send a mysql.log slice when it happens?
Thanks,
Aron
Comment #2
funana commentedHi Aron,
I use MySQL - 4.0.24-max. I will watch out for the error and send you the mysql log then.
Comment #3
alex_b commentedWhat's looking wrong is that li.fid is 0 and that the GROUP BY clause says "nid" and not "li.nid" - which semantically doesn't make a difference, but it surprises me that MySQL doesn't complain.
Comment #4
funana commentedIs there a solution?
Comment #5
alex_b commentedfunana,
Unfortunately not.
I don't have a MySQL 4.0 installation here at hand. The posted query works fine w/ 4.1. It would be great if you could play around w/ this query and come up with a solution. GROUP_CONCAT/SEPARATOR should be available in 4.0, probably it's a minor syntax issue.
If not, you could alternatively pull all feed item nodes and their term ids without grouping them, but ordering them by node id. You cold then group the tid by nid in PHP. I am afraid this could be slower than the current solution, though.
Alex