Bug #33022 Online backup does not preserve charsets for object names
Submitted: 5 Dec 2007 21:30 Modified: 22 Apr 2008 9:49
Reporter: Chuck Bell Email Updates:
Status: Duplicate Impact on me:
None 
Category:MySQL Server: Backup Severity:S3 (Non-critical)
Version:6.0 OS:Any
Assigned to: Rafal Somla CPU Architecture:Any

[5 Dec 2007 21:30] Chuck Bell
Description:
The backup kernel and object read/write do not store charsets when reading/writing objects. For example, the backup needs to be able to correctly restore a table name using its original charset. Similarly, the backup needs to store the charset and collation of databases.

How to repeat:
N/A Feature missing.

Suggested fix:
Implement charset as an attribute of the metadata. Send error if restoring a charset on a machine that does not have the charset.
[5 Dec 2007 21:33] Chuck Bell
This is from WL#4060:

      - Support charsets read/write strings (table names etc)   [1d]
[10 Apr 2008 8:22] Rafal Somla
HOW TO REPEAT
=============

mysql> create database y;
Query OK, 1 row affected (0.00 sec)

mysql> use y
Database changed
mysql> set names utf8
    -> ;
Query OK, 0 rows affected (0.00 sec)

mysql> create table ÿ (s1 int);
Query OK, 0 rows affected (0.08 sec)

mysql> backup database y to '60';
+-----------+
| backup_id |
+-----------+
| 18        |
+-----------+
1 row in set (0.15 sec)

mysql> set names latin1;
Query OK, 0 rows affected (0.01 sec)

mysql> restore from '60';
ERROR 1146 (42S02): Table 'y.ÿ' doesn't exist
[22 Apr 2008 9:49] Rafal Somla
This issue is addressed in BUG#33023.