ExpressionEngine CMS
Open, Free, Amazing

Thread

This is an archived forum and the content is probably no longer relevant, but is provided here for posterity.

The active forums are here.

error 1060 while updating from 2.1.4 to 2.2.1

July 14, 2011 5:38pm

Subscribe [4]
  • #1 / Jul 14, 2011 5:38pm

    John St-Amand

    865 posts

    Hi there - I’ve followed the updating instructions closely I thought, but in running the update wizard I got the following error:

    A Database Error Occurred
    Error Number: 1060

    Duplicate column name ‘batch_location’

    ALTER TABLE `exp_upload_prefs` ADD `batch_location` VARCHAR(255)

    Filename: updates/ud_215.php

    Line Number: 169


    Anything I can do about this?  Do I have to revert back to my backed up version of the site and try the update another way?  I was more concerned with add-ons, but this seems to have to do with upload preferences.

  • #2 / Jul 14, 2011 8:36pm

    richardmeredith

    48 posts

    Getting the exact same problem but upgrading from v2.2.0 to latest version v2.2.1 on EngineHosting.

    Cleared down the database and imported back up but same problem.

    ****UPDATE****

    Have a feeling I added the old safecracker folder whilst transferring the 3rd party stuff across. Not sure if that could have been the problem as I decided to clean install.

  • #3 / Jul 15, 2011 5:09am

    John Henry Donovan

    12339 posts

    John and Richard,

    There are several possible reasons for a duplicate table error:

    Did you try and run the upgrade twice?
    If the first upgrade failed make sure you restore the 1.6.8 database into a blank database otherwise it will merge with your EE2.x tables that were added on your first attempt

    Never use your browser’s Back button during an upgrade, as that can cause actions to run twice.

    Your server’s PHP max_execution_time may be set too low, forcing the upgrade script to end prematurely.
    Check with your host about increasing this value from the typical default of 30 seconds.

    If you’re using Firefox to perform the upgrade, try using Chrome or Safari instead. In some cases Firefox can re-send requests following a server error, effectively preventing the error from being seen.

    EE Wiki : Troubleshooting Upgrade Errors

  • #4 / Jul 15, 2011 5:19am

    richardmeredith

    48 posts

    Hi John,

    I did run the update twice, at first I had a different un-styled error message. Which then led to the message we are discussing when doing the second update.

    Seen the wiki article so I cleaned down and restored the database but was getting the same message on update. Was using Safari and site was on Enginehosting.

    I was lucky there wasn’t a lot of work on the site, so just done a clean install in the end

    John St-Amand how did you get on? interested to know.

    Thanks

    Rich

  • #5 / Jul 15, 2011 11:59am

    Sue Crocker

    26054 posts

    Hi, John.

    How how are things going? Let us know..

  • #6 / Jul 15, 2011 1:42pm

    John St-Amand

    865 posts

    I’m still stuck.  I did not attempt the update twice, so I’m a little unsure of how to proceed.  Should i do a clean install and then import to my database from my backup?

  • #7 / Jul 18, 2011 10:20am

    John St-Amand

    865 posts

    Really need to receive some direction on this.  I’m not sure what I should be doing next.  I’d like to get the DB back up and running right away, even if the old version - but ultimately i need to be able to complete the upgrade.  Can the duplicate tables be cleaned out in MyPHPAdmin?

  • #8 / Jul 20, 2011 11:23am

    Kevin Smith

    4784 posts

    Hey John,

    I saw your newer thread, and wanted to make sure this one got a response too. It sounds like you went ahead and pushed through with an update. Were you able to do so successfully without any errors from beginning to end?

    To answer the questions raised above, yes, duplicates can be removed using PHPMyAdmin. It sounds like, for whatever reason, we’re working with a dirty database here (i.e. a DB that has tables and/or columns it shouldn’t have). The best short-term solution in that case is to compare the DB to a stock 2.1.4 installation’s DB and remove from your installation all the tables or columns that shouldn’t be in the DB.

  • #9 / Jul 20, 2011 11:28am

    John St-Amand

    865 posts

    Unfortunately I’m having some problems with it at the moment, even though the update didn’t generate any errors when i went this way.  I did a fresh install and then imported the entire backup database.  And now i have the odd problem.  I created a new channel and tried to assign it to a user group for posting access and got an error.  And the member group preferences, such as what modules the members of that same group may access, don’t seem to be enforcing correctly either.

    Is there a suitable way for me to “clean” the database?  I’d certainly want to retain all entries, channels, field groups and templates - but i could setup member groups and reinstall all addons again from the start without any difficulty.  I’ve not really done too much in myPHPAdmin other than make a full backup or do an import of a full backup before, but I’m at least aware that table by table imports are possible too.  I’m just looking to clean up the mess the first upgrade attempt seems to have created.

  • #10 / Jul 20, 2011 11:41am

    Kevin Smith

    4784 posts

    Yep, I saw that on this thread, and responded asking for some more information about your database. Like I said over there, though, I suspect that we’re working with a corrupt database that wasn’t properly upgraded. Rather than poke around trying to fix stuff in the upgrade (and still potentially missing something), I think what we’ll probably end up needing to do is try the upgrade again from scratch.

    Let’s get some results on that other thread first, but if the results look like I expect, we’ll likely close that one down and move it back over here to try the upgrade again. Don’t worry; I’m going to make sure you get taken care of. Do you have a solid backup of your database and file system as it was at 2.1.4?

  • #11 / Jul 20, 2011 11:44am

    John St-Amand

    865 posts

    Yes, though because on the surface the update had seemed successful, work has continued on the site - so I will make an update of the database as it is now as well to ensure entries and template changes in particular are still available to me.

  • #12 / Jul 21, 2011 4:23pm

    Kevin Smith

    4784 posts

    Hey John,

    So after the resolution we found on the other thread, is everything ok on this one? Am I good to close this thread up, too?

  • #13 / Jul 21, 2011 4:25pm

    John St-Amand

    865 posts

    Yep. All good. THanks!

  • #14 / Jul 21, 2011 4:26pm

    Kevin Smith

    4784 posts

    Great! Glad we got it all fixed up!

.(JavaScript must be enabled to view this email address)

ExpressionEngine News!

#eecms, #events, #releases