I can restore from
mysqldump wordpress-db > mysqldump-wpdb.sql
to new DB fine with
$ sudo mysql wordpress-db001 < mysqldump-wpdb.sql
But if the DB already exists (as they generally do with a restore...!), I get error:
ERROR 1050 (42S01) at line 2084: Table 'wp_commentmeta' already exists
I don't think it's anything to do with permissions of root (ie used by sudo), just a standard problem. The error makes sense and is a good warning, but I can't find where to simply overwrite or DROP all the existing objects - does that have to be coded manually into the .sql or is there an easier way to do this?