Download & Extend

update menu module as SQL friendly

Project:Drupal core
Version:6.x-dev
Component:database system
Category:bug report
Priority:critical
Assigned:hswong3i
Status:closed (fixed)

Issue Summary

minor update about query format. P.S. we need to use db_query() correctly for cross database concern :)

AttachmentSizeStatusTest resultOperations
drupal-6.x-dev-menu.module-0.1.diff3.62 KBIgnored: Check issue status.NoneNone

Comments

#1

Priority:normal» critical

since both Oracle/DB2/MSSQL will preform A LOT OF reserved word rewrite handling to query BODY, this patch can greatly improve the ability of cross database compatibility. This is because all user input values are escaped, and will not capture by rewrite handling.

#2

minor update about %s, thanks for dmitrig01 :)

AttachmentSizeStatusTest resultOperations
drupal-6.x-dev-menu.module-0.2.diff3.64 KBIgnored: Check issue status.NoneNone

#3

Status:needs review» reviewed & tested by the community

#4

Status:reviewed & tested by the community» fixed

I see the general push to move literal stuff out of queries could help database compatibility, although fail to see in this case, what character might be infected by any DB escaping. Anyway, committed just to be in-line with this process.

#5

Gábor wrote : "I see the general push to move literal stuff out of queries could help database compatibility"

Actually this is not documented anywhere AFAIK, at least it is not documented in the module update handbook page (http://drupal.org/update/modules). With all these SQL-compatibility patches going into core we will have core ready, but you will hardly find any contributed module that will not break your site immediately ;)

#6

We'v discussed this in the installer issue (which AFAIR is not yet committed). This change in policy should definitely be documented.

#7

hmmm, this code may need to be cleaned up a little in addition - it assumes the 'navigation' menu- but that was written when we didn't allow the link to move outside of that.

#8

Status:fixed» closed (fixed)
nobody click here