I'm not 100% sure it's because of that, but in call to db_next_id there is {} (table translation?) used, which probably shouldn't be there. After my patch id gets properly updated.

CommentFileSizeAuthor
i18_node.inc-4.5.0.patch656 bytesahwayakchih

Comments

jose reyero’s picture

Acually, that table translation *must* be there. Otherwise, this won't work with table prefixing.

Whatever it is the problem, should be somewhere else.

Please, could you be more descriptive about the bug? Did you install a clean copy of i18n module or did you update from some previous version? Are you using table prefixing?

I guess, it may be the opposite: db_next_id not using table prefixing, then I fixed it, then if you update the module, the sequence gets out of sync.

Could you check your 'sequences' table manually and let us know?

ahwayakchih’s picture

You're right - indeed prefixing is used in other places.
So it had to be something else, sorry.

I tried to "fix it" because translations were getting messed up. When i checked sequences table id was much to low, what's more: i18n_node table's trid was the same for ALL new translations. That's why i thought it's a problem with db_next_id.
Now it seems to work ok, but i also had to fix id in sequences table (i've set it to last trid used, after i manually fixed trid numbers in i18n_node table). So this prefix patch may have no impact on functionality when someone doesn't use db prefix.

I'm not using db prefixing. I'm using drupal 4.5.2 with last release of Internationalization (so 4.5.0). New installation.

Hmm... i make backup of db before and after i manage to install something and configure it to make it work ok. Once i had to bring back backuped db, so it may be that some old things were left (i was sure that backup overwrites db, but it may be that it just updates it, leaving old things not mentioned in backup :(

Sorry for bothering, looks like it was my fault after all :)

jose reyero’s picture

No problem. Actually, I should have put a note somewhere when fixing that bug, as it caused sequences to be out of sync in some cases.

Closing this one.