Restoring a backed up database - \0 character causing errors

Hello all,

I’m trying to create the XWiki database from a backup as described here: https://www.xwiki.org/xwiki/bin/view/Documentation/AdminGuide/Backup

I’m on Windows, using MySQL.

When sourcing the backup.sql file I get the below error.

ERROR: ASCII '\0' appeared in the statement, but this is not allowed unless option --binary-mode is
enabled and mysql is run in non-interactive mode. Set --binary-mode to 1 if ASCII '\0' is expected.

Doing a more on the backup.sql file does indeed confirm that the file contains the \0 character at various locations in the ‘activitystream_events’ table.

I’ve tried using --binary-mode=1 but still getting errors relating to \0. What am I doing wrong?

Thanks,
Ben

I managed to fix this by using the --result-file="Pathdump.sql" sqldump option when exporting the database. It looks like this might be needed for Windows based MySQL.