mysqldatabasedatabase-schemadumpdatabase-dump

mysqldump - exclude some table data


Is it possible, using mysql dump to export the entire database structure, but exclude certain tables data from export.

Say the database has 200 tables, I wish to export the structure of all 200 tables, but i want to ignore the data of 5 specific tables.

If this is possible, how is it done?


Solution

  • As per the mysqldump docs:

    mysqldump name_of_db --ignore-table=name_of_db.name_of_table