in reply to OT: Trying to append mysql dump into DB

Consider reading the documentation for mysqldump, which also shows how to make the program only dump the data instead of recreating the tables.

Alternatively, you could write a Perl program that parses through the SQL file and removes the unwanted statements. This would not be hard and you have already received help on similar topics.

  • Comment on Re: Trying to append mysql dump into DB

Replies are listed 'Best First'.
Re^2: Trying to append mysql dump into DB
by ravi45722 (Pilgrim) on Sep 10, 2015 at 12:12 UTC

    I replaced my code like this. Its skipping the DROP & CREATE statements in the .sql file. Now its executing in so less time. Thanks for information

     mysqldump -u root -h $host $db $table --no-create-info --where="Date='$date'"> db_backup.sql