Download & Extend

Removing a node creates an error when running Drupal with PostgreSQL

Project:WYSIWYG image upload - Inline images for your WYSIWYG
Version:6.x-2.9
Component:Code
Category:bug report
Priority:major
Assigned:Unassigned
Status:needs review

Issue Summary

The SQL query for removing wysiwyg_imageupload entries is MySQL specific and does not work under PostgreSQL. I have attached a patch against wysiwyg_imageupload-6.x-2.9 that fixes the problem. The SQL code in the patch is very generic, thus should work with most RDBMSs.

AttachmentSize
wysiwyg_imageupload_pgsql.patch901 bytes

Comments

#1

is there no way to deal with that issue with one query?

#2

Why is having 2 queries a problem?

Postgres does not support more than 1 table per DELETE FROM request (see http://www.postgresql.org/docs/8.4/static/sql-delete.html). I think ANSI SQL also allows only 1 table per DELETE request.

Maybe you could wrap both queries in one db_query call, but I don't know how.

#3

Status:active» needs review

I see. Well then lets finally take that one in. Can you confirm that this is working with MYSQL without issues?

#4

I did some basic testes under MySQL and it works.

nobody click here