dbdelta duplicates indices instead of overwriting them.
|Reported by:||majelbstoat||Owned by:||ryan|
|Severity:||normal||Keywords:||dbdelta duplicate indices|
When using dbdelta to upgrade a plugin's tables, any UNIQUE keys on that table are duplicated, because they are added without being removed first. This seems to occur when the table structure is changed in some way, even when the SQL is identical to that outputted by phpMyAdmin.
http://comox.textdrive.com/pipermail/wp-hackers/2006-April/006046.html for the original discussion.
I also had a problem where dbdelta tries to duplicate multiple primary keys as well. I'll do some more testing on this and see if I can narrow down the cause.
Change History (12)
- Keywords bg|commit removed
- Resolution set to invalid
- Status changed from reopened to closed