Description:
I'm using 6.0-backup.
This is the latest version, the one that doesn't
allow BACKUP DATABASE inside CREATE EVENT.
I say CREATE EVENT ... BACKUP DATABASE ...
(This fails. Okay.)
I create a table named t.
I say BACKUP DATABASE.
I say RESTORE.
The restore fails with this error message:
ERROR 1064 (42000): You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '; CREATE TABLE `t` (
`s1` int(11) DEFAULT NULL
) ENGINE=MyISAM DEFAULT CHARSET' at line 1
How to repeat:
mysql> use test
Database changed
mysql> create event e on schedule every 1 second do backup database b to 'b';
ERROR 1314 (0A000): BACKUP is not allowed in stored procedures
mysql> create database d5;
Query OK, 1 row affected (0.00 sec)
mysql> use d5
Database changed
mysql> create table t (s1 int);
Query OK, 0 rows affected (0.01 sec)
mysql> backup database d5 to '43';
+-----------+
| backup_id |
+-----------+
| 1 |
+-----------+
1 row in set (0.39 sec)
mysql> restore from '43';
ERROR 1064 (42000): You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '; CREATE TABLE `t` (
`s1` int(11) DEFAULT NULL
) ENGINE=MyISAM DEFAULT CHARSET' at line 1