User Tools

Site Tools


mysql:exclude_drop_and_create_table_from_mysqldump

MySQL - Exclude DROP and CREATE TABLE From mysqldump

How do you dump data from a mysql database table without the drop and create tables showing up before the inserts?

The following solution will just give you a list of insert statements. Simply use the options –skip-triggers –compact –no-create-info.

Here is an example.

mysqldump --skip-triggers --compact --no-create-info -u <username> -p <password> <database> <tables>
mysql/exclude_drop_and_create_table_from_mysqldump.txt · Last modified: 2020/07/15 09:30 by 127.0.0.1

Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki