0

I have a db and looking for a mysql commands to extract Extract DDL and DML and Exclude tables which are not required

could you please let me know how we can do it via command prompt?

Thanks, Kathir

0

1 Answer 1

2

Mysqldump:

http://dev.mysql.com/doc/refman/5.1/en/mysqldump.html

able to dump DDL/DML and has option for exclude list of tables:

http://dev.mysql.com/doc/refman/5.1/en/mysqldump.html#option_mysqldump_ignore-table

Sign up to request clarification or add additional context in comments.

2 Comments

can you pls specific the command for DDL as well as DML?
for ddl: mysqldump -uroot -pmysql --no-data testdb > testdb_exported_ddl_file.sql for dml: mysqldump -uroot -pmysql --skip-triggers --no-create-info --ignore-table=testdb.emp_table --ignore-table=testdb.emp_history testdb > testdb_dml.sql

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.