Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
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.
Comment | File | Size | Author |
---|---|---|---|
#1 | i18n-taxonomy.patch | 725 bytes | mailleux |
Comments
Comment #1
mailleux CreditAttribution: mailleux commentedI 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.
Comment #2
Jose Reyero CreditAttribution: Jose Reyero commentedPatch applied.
Thanks
Comment #3
(not verified) CreditAttribution: commented