Create MySQL Dump that ignore duplicate key error when import back to MySQL
Answer:
When you import a dump file created by the mysqldump command, to a non-empty database, duplicate key error such as "Duplicate entry 'X' for key 'Y'" might occur.
To ignore this error, simply use the following command:
# mysqldump my_db my_table --insert-ignore