I was wondering if I can prevent mysqldump inserting this commands
/*!50017 DEFINER=`root`@`localhost`*/
Or if I have to do it afterwards with sed, for example
Thanks!
This issue has been around since 2006 with no sign of ever being fixed.
I have, however, piped it through grep (linux only) to trim out the definer lines before writing the dump file:
mysqldump -u dbuser -p dbname | grep -v 'SQL SECURITY DEFINER' > dump.sql
A bit of a mouthful (or keyboardful?) but I think it's the only way.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With