With i18n active when I set the language for a Vocabulary I get and error on postgres.

query: UPDATE term_data t SET t.language='en' WHERE t.vid=1 in /var/drupal/includes/database.pgsql.inc on line 113.

I found the query is in i18n/i18n.inc line 218:

db_query("UPDATE {term_data} t SET t.language='%s' WHERE t.vid=%d", $edit['language'], $edit['vid']);

I changed it for (and it works):

db_query("UPDATE {term_data} SET language='%s' WHERE vid=%d", $edit['language'], $edit['vid']);

I don't believe the t alias is really needed, it breaks on Postgres.

CommentFileSizeAuthor
#1 i18n-taxonomy.patch725 bytesmailleux
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

mailleux’s picture

FileSize
725 bytes

I put my local fix into a patch. It should work with:

cd <drupal dir>
patch -p0 < ~/i18n-taxonomy.patch

At least works on my install.

Jose Reyero’s picture

Status: Active » Fixed

Patch applied.
Thanks

Anonymous’s picture

Status: Fixed » Closed (fixed)