Solved

MySQL 4 to MySQL 5

Posted on 2013-05-31
3
300 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
3 Comments
 
LVL 23

Accepted Solution

by:
nemws1 earned 500 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 83

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

Enterprise Mobility and BYOD For Dummies

Like “For Dummies” books, you can read this in whatever order you choose and learn about mobility and BYOD; and how to put a competitive mobile infrastructure in place. Developed for SMBs and large enterprises alike, you will find helpful use cases, planning, and implementation.

Question has a verified solution.

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

I use MySQL for many of my development projects in a Windows environment. To manage my databases (and perform queries) for years I used a tool called MySQL administrator.  This tool has since been replaced by MySQL Workbench. So I decided to m…
Does the idea of dealing with bits scare or confuse you? Does it seem like a waste of time in an age where we all have terabytes of storage? If so, you're missing out on one of the core tools in every professional programmer's toolbox. Learn how to …
Microsoft Active Directory, the widely used IT infrastructure, is known for its high risk of credential theft. The best way to test your Active Directory’s vulnerabilities to pass-the-ticket, pass-the-hash, privilege escalation, and malware attacks …
Email security requires an ever evolving service that stays up to date with counter-evolving threats. The Email Laundry perform Research and Development to ensure their email security service evolves faster than cyber criminals. We apply our Threat…

830 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