April 18, 2012

exporting and uploading mysql database from dev to production

Question by jpporterVA

I am in the process of implementing an upgrade to my small website that consists mainly of adding 13 tables to my mysql database, loading a few rows into each (type codes and reference data). I was able to do a release previously when I created the database in production and populated it with one table.

I created that one by hand via the php mysql admin tool (shared hosting at godaddy), and I guess I can do the same thing again since my release is still small. But, I’d like to know what some of the best ways to upload the database to production would be. I’d like to be able to take a snapshot of the database tables along w/ the contents of some of the reference tables and ftp them to production and load them. And, I’d like to know what is best to use for more complicated sites (which my site is going to be over time) and accounts for any procedures or triggers (which I don’t have yet).

Since my site is live, i don’t want to figure this out with trial and error while it’s down, so . your suggestions are appreciated in advance.

Answer by Starx

Here is a pictured tutorial of how you can do this using phpMyAdmin.

Author: Nabin Nepal (Starx)

Hello, I am Nabin Nepal and you can call me Starx. This is my blog where write about my life and my involvements. I am a Software Developer, A Cyclist and a Realist. I hope you will find my blog interesting. Follow me on Google+

...

Please fill the form - I will response as fast as I can!