Folks,
I find it useful for browsing to dump each table of a DB, i.e. psuedo-code like
foreach table mysqldump --add-drop-table DB table > table
This produces a file per table, and that file has the DDL and data.
My question: does this per-table version capture all the information that doing a full-DB dump (as follows) would?
mysqldump --add-drop-table DB > DB
Not necessarily, because you may have updates occuring to other tables, while a given table is being dumped. If the database is being used in read-only fashion during the dump, the information should be the same in both cases.
I tested, and noticed that foreign key constraints and indexes (in my InnoDB database) are appearing nicely in the per-table version. Is anything missing?
Shouldn't be. If you have problems reloading the table due to the order in which the InnoDB tables appear in the dump files, add
SET FOREIGN_KEY_CHECKS = 0;
to the beginning of the file before reloading it.
I'm using mysql "Ver 12.18 Distrib 4.0.12" (I assume 4.0.12) for Linux. Thanks for any thoughts.
Dan
-- Dan Frankowski [EMAIL PROTECTED]
-- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe: http://lists.mysql.com/[EMAIL PROTECTED]
-- Paul DuBois, Senior Technical Writer Madison, Wisconsin, USA MySQL AB, www.mysql.com
Are you MySQL certified? http://www.mysql.com/certification/
-- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe: http://lists.mysql.com/[EMAIL PROTECTED]