Closed (fixed)
Project:
Image
Version:
4.6.x-1.x-dev
Component:
image.module
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
14 Feb 2006 at 22:54 UTC
Updated:
1 Jul 2007 at 23:46 UTC
Mysql 5.0.12 and up has changed the join semantics slightly. This patch fixes a place where the use of db_rewrite_sql could potentially generate the error: "Unknown column 'n.nid' in 'on clause'", when the node_privacy_byrole module (or a different access control module) is active.
For more info see: http://drupal.org/node/43735#comment-92865
| Comment | File | Size | Author |
|---|---|---|---|
| image.module_13.patch | 825 bytes | starbow |
Comments
Comment #1
chook commentedI'm using simple access and I've been waiting for a patch to come along for this, but when I log out here is what i see.
Fatal error: Unknown column 'n.nid' in 'on clause' query: SELECT DISTINCT(n.nid), n.title, n.body, f.* FROM files f INNER JOIN node_access na ON na.nid = n.nid , node n WHERE (na.grant_view = 1 AND CONCAT(na.realm, na.gid) IN ('all0','simple_access0')) AND f.nid = n.nid AND f.fid = 7 in /home/.haywire/gourd/masha.barashek.org/includes/database.mysql.inc on line 66
Comment #2
chook commentedSorry if I'm putting this into the wrong place.
I just tried it out with the node_privacy_by_role module and it seems to work fine.
Comment #3
starbow commentedThis patch only fixes the problem in respect to the image.module. The logout issue is another manifestation of the same underlying problem, but this patch will not fix it.
I think it's been fixed at the source for 4.7, but still crops up all over the place in 4.6.
Comment #4
drewish commentedThis version is no longer supported. If this issue is occurring with a more recent version please open a new issue.