How do I change the DEFINER of a VIEW in Mysql? When I run mysqldump, I get an error:

mysqldump: Got error: 1449: The user specified as a definer ('root'@'foobar') does not exist when using LOCK TABLES


This makes sense because foobar is a legacy machine that no longer exists.

How do I change the definer of all my tables to 'root'@'localhost'?
Easier to use the --single-transaction switch:

mysqldump --single-transaction -u username -p db &gt; db.sql