?
Solved

MySQL 4 to MySQL 5

Posted on 2013-05-31
3
Medium Priority
?
310 Views
Last Modified: 2013-05-31
Our web host is forcing us to go to MySQL 5. I'm sure there are a lot of good reasons, I don't have time to be forced to do this RIGHT NOW.

I have been lead to believe that I will have to export ALL the current SQL content, create a new MySQL 5 database & import it all back in.

Is that true?

We have maybe 200 php programs, all of which we would have to change the connection string on.

Is there an easier way to do this?
0
Comment
Question by:Richard Korts
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 23

Accepted Solution

by:
nemws1 earned 2000 total points
ID: 39211245
Well, if you're going through your code anyways, you might want to put your connection string into a library and then load that into all your code.  Next time, you'll only have to update one line.  Or better yet... create a library that maps each project/application to a connection string - then you can use multiple servers and only have 1 file to update.  I know ... hindsight is 20/20. ;-)

You are correct for the most part.  It's been *years* since I upgrade to MySQL 5, so its hard to remember any caveats, but I don't remember any all-night-long process or anything similar to that.  If there were any issues, I was able to fix them easily (and I didn't know as much about SQL then as I do now)
0
 

Author Comment

by:Richard Korts
ID: 39211274
To nemws1,

Yes, of course, I should do that anyway. If this project continues, we will go to another host anyway.

Thanks
0
 
LVL 84

Expert Comment

by:Dave Baldwin
ID: 39211641
If you change hosts, you can probably expect to be put on a server with newer versions of everything, PHP, MySQL, and Apache.  Nobody is going backwards and keeping old versions on new servers.  I think I have one site left on PHP4 and MySQL4 and that host would really like me to move to a newer server so they can shut that one down.

Note that PHP 5.3 and 5.4 are pickier about a lot of errors than previous versions.  They have also removed / obsoleted some functions.  You probably want to make a plan to upgrade before you are forced to and find your code stops working.
0

Featured Post

Prepare for your VMware VCP6-DCV exam.

Josh Coen and Jason Langer have prepared the latest edition of VCP study guide. Both authors have been working in the IT field for more than a decade, and both hold VMware certifications. This 163-page guide covers all 10 of the exam blueprint sections.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Containers like Docker and Rocket are getting more popular every day. In my conversations with customers, they consistently ask what containers are and how they can use them in their environment. If you’re as curious as most people, read on. . .
In this blog post, we’ll look at how using thread_statistics can cause high memory usage.
In this video, Percona Solution Engineer Dimitri Vanoverbeke discusses why you want to use at least three nodes in a database cluster. To discuss how Percona Consulting can help with your design and architecture needs for your database and infras…
In this video, Percona Solution Engineer Rick Golba discuss how (and why) you implement high availability in a database environment. To discuss how Percona Consulting can help with your design and architecture needs for your database and infrastr…

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question