I've tested a direct upgrade from 1.0 to 1.3-alpha2.

Update #6137

    * Failed: ALTER TABLE {nodewords} ADD INDEX nodewords_id (id(6))
    * Failed: ALTER TABLE {nodewords} ADD INDEX nodewords_type (type(6))
    * user warning: Duplicate key name 'nodewords_id' query: ALTER TABLE nodewords ADD INDEX nodewords_id (id(6)) in includes\database.mysql-common.inc on line 434.
    * user warning: Duplicate key name 'nodewords_type' query: ALTER TABLE nodewords ADD INDEX nodewords_type (type(6)) in includes\database.mysql-common.inc on line 434.

Comments

avpaderno’s picture

Version: 6.x-1.3-alpha2 » 6.x-1.x-dev
Status: Active » Fixed

The update 6137 is destined to fail, if you are updating from version 6.x-1.0.
The code has been already changed, and it doesn't try to add the new indexes if the update 6113 is first executed.

hass’s picture

Not sure yet what you have changed, but If you are not sure that a index/keys exists, remove them first and than add it back again. This is how it could be safely done without any errors. I'm sure there are such example(s) in core system update...

avpaderno’s picture

Not sure yet what you have changed, but If you are not sure that a index/keys exists, remove them first and than add it back again.

In that case, you would get an error if the index the code is trying to remove doesn't exist; you still would see an error about a failed SQL query, in the same way you see it now.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.

summit’s picture

I have this error also moving from 1.0 to 6.x-1.x-dev (2010-Dec-02).
What should I do now? Does it need altering, or is it ok to let the error be?

Thanks a lot in advance for your reply!
greetings, Martijn