Project:Directory
Version:6.x-1.0-alpha1
Component:Code
Category:bug report
Priority:normal
Assigned:Unassigned
Status:closed (fixed)

Issue Summary

I'm new here, so pl. let me know if I'm doing something wrong.

I'd been seeing a recurring SQL SELECT error message every time I updated the directory settings. Also noticed that the node counts were not displaying.

I traced it to the function and the SQL queries:

        $result = db_query(db_rewrite_sql('SELECT t.tid, n.nid FROM {term_node} t JOIN {node} n ON t.nid = n.nid WHERE n.status = 1', 't', 'tid'));
 

which I changed to:
        $result = db_query(db_rewrite_sql('SELECT t.tid, n.nid FROM {term_node} t LEFT JOIN {node} n ON t.nid = n.nid WHERE n.status = 1', 't', 'tid'));
 

essentially adding the LEFT keyword to JOIN.

I tried this first with the official release version and then with the dev version with identical results.

Was this an oversight, incorrect code version or a real bug?

Thanks

Comments

#1

Hello fsiddiqi, thanks for the report.

Since it is a SQL error, it would be appropriate to give the SQL engine (mysql?) and version that you are using.
Also, can you copy the exact error message that you get?

Thank you for providing a solution, too.

#2

Sorry I should have specified.

This problem occurred for me on MySQL 3.23 and was reported as a SQL syntax error.

Thanks

#3

Version:5.x-1.x-dev» 6.x-1.0-alpha1
Status:active» fixed

MySQL 3.x is no longer supported by Drupal.

See the new D6 alpha release announcement:
http://drupal.org/node/283259

#4

Status:fixed» closed (fixed)

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