[vox-tech] Export MySQL DB to flat file

David Hummel dhml at comcast.net
Mon Oct 25 12:38:33 PDT 2004


On Mon, Oct 25, 2004 at 12:20:53PM -0700, Dylan Beaudette wrote:
> I was wondering if there is any such tool in the MySQL utils that will
> save something like a CSV file that represents the records in the
> DB...  something like mysqldump, but without all of the SQL code mixed
> with the data...

See the -T flag to mysqldump:

  $ mysqldump -T /path/to/dbdump mydb

This must be run on the machine where mysqld is running, and the
/path/to/dbdump must be writeable by the user running mysqld.

This will create both *.sql and *.txt files.  The *.txt files are
tab-delimited files.  You may need to change the '\N's to something M$
SQL server can understand.

-David


More information about the vox-tech mailing list