[drupal-devel] [bug] SQL error when node_access is used
chx
drupal-devel at drupal.org
Wed Feb 23 07:15:31 UTC 2005
Project: Drupal
Version: cvs
Component: taxonomy.module
Category: bug reports
Priority: critical
Assigned to: Anonymous
Reported by: tangent
Updated by: chx
Status: patch
Attachment: http://drupal.org/files/issues/nodeaccess_0.patch (1.21 KB)
Handbook updated, thanks for warning. +1 on this.
chx
Previous comments:
------------------------------------------------------------------------
February 23, 2005 - 08:03 : tangent
Attachment: http://drupal.org/files/issues/nodeaccess.patch (1.21 KB)
I am testing the nodeperm_role.module and I experienced an SQL error
when node permissions are changed.
The problem is that the query in question uses "INNER JOIN {term_node}
USING (tid)" but the db_rewrite_sql() function adds another inner join
in front of this one so the USING clause breaks. My patch changes all
the USING statements to ON to prevent this.
Perhaps the documentation for db_rewrite_sql() should be updated to
warn against the use of the USING clause. I don't see any other
instances of it in core but many contrib modules use it.
--
View: http://drupal.org/node/17794
Edit: http://drupal.org/project/comments/add/17794
More information about the drupal-devel
mailing list