Jump to:

23472 Posts in 18941 Topics by 2878 members

General Questions

SilverStripe Forums » General Questions » [SOLVED] Urgent help needed - MySQL and migrating sites

General questions about getting started with SilverStripe that don't fit in any of the categories above.

Moderators: martimiz, Sean, biapar, Willr, Ingo, swaiba, simon_w

Page: 1
Go to End
Author Topic: 934 Views
  • Harley
    Avatar
    Community Member
    153 Posts

    [SOLVED] Urgent help needed - MySQL and migrating sites Link to this post

    Hello,

    I'm migrating my sites this weekend to a new hosting provider, I've uploaded one of my silverstripe sites but I'm hitting an error when importing the database tables. Basically for each page type in the database it is throwing up a mysql " #1062 - Duplicate entry '32' for key 'PRIMARY' " error message.

    There is no duplication in the database, the ID field is set to 'int(11)' so by my understanding everything should be ok.

    Anyone else ever experienced this?

    Any help or advice will be most appreciated

    Thanks

  • patjnr
    Avatar
    Community Member
    101 Posts

    Re: [SOLVED] Urgent help needed - MySQL and migrating sites Link to this post

    Hi

    try dropping every table in your DB and copy the mysql dumb. in Myphpadmin click on SQL and NOT import this time and paste your dumb in and go.

    thats how i do it without any problems.

    yell if not working.

    ta

  • Harley
    Avatar
    Community Member
    153 Posts

    Re: [SOLVED] Urgent help needed - MySQL and migrating sites Link to this post

    Thank you so much, it seems to obvious now! Worked like a charm!

    Thanks again

  • patjnr
    Avatar
    Community Member
    101 Posts

    Re: [SOLVED] Urgent help needed - MySQL and migrating sites Link to this post

    What solution work for you.

  • Harley
    Avatar
    Community Member
    153 Posts

    Re: [SOLVED] Urgent help needed - MySQL and migrating sites Link to this post

    Here are the steps I had taken:

    1. Export database with Compression set to 'none' from the original database
    2. Copy and paste the database which is displayed in the window (paste it into a txt file to be safe if you wish)
    3. Open phpMyAdmin on the server I wish to migrate to.
    4. Click on 'SQL' and paste into the window the database I copied earier
    5. Hit ok and everything goes in perfectly

    These are the little things that are sometimes good to know. Atleast there is a post here now for future reference.

    Thanks again for your help

    934 Views
Page: 1
Go to Top

Want to know more about the company that brought you SilverStripe? Then check out SilverStripe.com

Comments on this website? Please give feedback.