Mysql 5 & db_rewrite_sql issue
starbow - February 14, 2006 - 22:46
| Project: | Drupal |
| Version: | 4.6.9 |
| Component: | taxonomy.module |
| Category: | bug report |
| Priority: | normal |
| Assigned: | Unassigned |
| Status: | duplicate |
Jump to:
Description
Mysql 5.0.12 and up has changed the join semantics slightly. This patch fixes 2 places where the use of db_rewrite_sql is generating the errors: "Unknown column 'n.nid' in 'on clause'", when the node_privacy_byrole and image modules are active.
For more info see: http://drupal.org/node/43735#comment-92865
| Attachment | Size |
|---|---|
| taxonomy.module_16.patch | 1.09 KB |

#1
is this a issue for cvs/head too?
if so please provide a patch
#2
yes, although there might be a patch to db_rewrite_sql that fixes this once and for all.
it's not clear if/when that's going to get applied, however, so we'll have to follow that issue to see what we should do about this one.
thanks,
-derek
#3
FYI: the fix listed in my previous comment just got applied to HEAD, so this will no longer be an issue for 4.7 and beyond. therefore, this patch is *just* for 4.6 compatibility with MySQL 5.0.12+. i'd still vote on getting it in, just in case a 4.6.6 is released, since it'd be nice for us to support modern MySQL and the fix is small and well-understood. thanks.
#4
in fact, setting this to RTBC...
#5
It would be nice if one or two other people could test this patch for a while.
#6
I am willing to test. Where are the patched modules for 4.6.5?
#7
See the link above.
#8
actually, i think the better solution to this problem is to just fix db_rewrite_sql() ala #51850... but that's a bigger, potentially more scary change. however, if we did that, we wouldn't need to do this...
#9
per dww's comment this needs work.
#10
I'm closing this one and forward it to http://drupal.org/node/51850
Both issues talk about the same problem in two similar ways, but the other thread has more posts and, supossedly, more information.
@dww: please take a look at the other thread, to see if we can do something about it. Thank you.