Following suggestions at the issue at http://drupal.org/node/648598 I just updated to the latest dev version from beta5, and got the following errors on running update.php (which called Update #6103 for the path_redirect module ):
user warning: Can't DROP 'path_language'; check that column/key exists query: ALTER TABLE path_redirect DROP KEY path_language in /srv/www/vhosts/www.opendemocracy.net/includes/database.mysql-common.inc on line 417.
user warning: Duplicate entry '' for key 2 query: ALTER TABLE path_redirect CHANGE `path` `source` VARCHAR(255) NOT NULL in /srv/www/vhosts/www.opendemocracy.net/includes/database.mysql-common.inc on line 520.
user warning: Key column 'source' doesn't exist in table query: ALTER TABLE path_redirect ADD UNIQUE KEY source_language (source, language) in /srv/www/vhosts/www.opendemocracy.net/includes/database.mysql-common.inc on line 403.
Unsurprisingly, this has meant I've had to disable path_redirect, or face error messages about "Unknown column 'source'" etc. on every page view. How can I fix this? Is uploading beta5 enough, or has the database been changed in such a way that I can't?
Comments
Comment #1
Tom Ash commentedAnyone? Can I just go back to beta5, or do I need to roll back some changes to the database upgrading to dev will have made?
Also, am I right in guessing that the source of my errors was going straight from beta5 to dev rather than passing through beta6 first? Or if not, then how should I upgrade to dev?
Comment #2
Tom Ash commentedI have an old local copy of the site with Path Redirect beta5 working, and am wondering whether I can use this to get Path Redirect (ideally the current dev version) working on the live site.
One possibility would be to export the redirects from the old local copy and then import them in some way to Path Redirect dev on the live site. But it looks from http://drupal.org/node/158547 that import is not yet built into the module. It seems the quickest way may to be write a SQL script which takes the beta5 table and puts it in a state which will work with dev. I'll look into this as soon as I have time to do so, but any help would be much appreciated :)
Comment #3
sansui commentedI'm on beta-6, but I was also looking to upgrade to dev version. Is there an upgrade path or do I need to completely uninstall, install new dev, and redo all my redirects?
Comment #4
dave reidI just ran an upgrade from 6.x-1.0-beta5 to 6.x-1.x-dev and it worked perfectly.
Comment #5
Tom Ash commentedThat's worked fine for me too on copies where we never updated to beta6, but doesn't solve the problem of what to do for those where we did...
Comment #6
dave reidWhat you should be able to do is go into your path_redirect table manually, find the rows that have the same value in the 'path' column, delete all but one of them, and then run the following SQL: