Top

mySQLdump Complete Insert


mySQL Code
+ 0 likes
Please Register to submit score.
Bookmark and Share
Average Score  0.0 (of 0 scores)
Date Added  Mar 28, 2007
Last Updated  Mar 28, 2007
Tags  complete  insert 

Introduction

This is more of a note to myself, but I use it to dump databases where there are additional fields in the new table. When you're upgrading a database you can either add the new fields to the old table or move the data from an older table to a newer one.

I usually like to add the new fields, but when it's a major upgrade I just start with a fresh, current table. That's where this code comes in handy. You use this to dump the data from the older table. That way it can be inserted into the newer table without any hassles over an incompatible number of fields.

Grab the Code

mysqldump --complete-insert database table > table.sql

Comments

  (4)  RSS
Joshuaxiong1
Comments: 127
 
mySQL Snippet:  mySQLdump Complete Insert
Posted on Aug 24, 2008 10:07 pm
huh?
Gummo
Comments: 153
 
mySQL Snippet:  mySQLdump Complete Insert
Posted on Aug 24, 2008 10:53 pm
Edit: Didn't mean to comment. -.-
Eugenio
Comments: 1,193
 
mySQL Snippet:  mySQLdump Complete Insert
Posted on Aug 24, 2008 11:00 pm
rofl
Hawkee
Comments: 1,039
 
mySQL Snippet:  mySQLdump Complete Insert
Posted on Aug 24, 2008 11:08 pm
This is really just a command line call that will give you a dump of your mySQL database. It's helpful for importing older data into a newer structure.

Commenting Options

Register or Login to Hawkee.com or use your Facebook or Twitter account by clicking the corresponding button below.

  
Bottom