Bug #9373 after alter table engine...
Submitted: 24 Mar 2005 5:46 Modified: 20 Apr 2005 12:29
Reporter: bongkeun oh Email Updates:
Status: Won't fix Impact on me:
None 
Category:MySQL Cluster: Cluster (NDB) storage engine Severity:S2 (Serious)
Version:4.1.10 OS:Linux (redhat)
Assigned to: Assigned Account CPU Architecture:Any

[24 Mar 2005 5:46] bongkeun oh
Description:
show example...

1) in case tabel engine 'MyISAM' or 'innoDB'...

mysql> select pollc_id, cate_code from tbl_pollconfig where cate_code='ROOT';
+----------+-----------+
| pollc_id | cate_code |
+----------+-----------+
|        1 | ROOT      |
|        2 | ROOT      |
+----------+-----------+
2 rows in set (0.00 sec)

2) in case table engine 'NDBCLUSTER'...

mysql> alter table tbl_pollconfig engine=NDBCLUSTER;
Query OK, 2 rows affected, 2 warnings (6.67 sec)
Records: 2  Duplicates: 0  Warnings: 0

mysql> select pollc_id, cate_code from tbl_pollconfig where cate_code='ROOT';
Empty set (0.01 sec)

cf) other table is not problem... only tbl_pollconfig table is problem..
sorry... i don't use english very well...

How to repeat:
email...
to : ovclas@empal.com
[24 Mar 2005 5:48] bongkeun oh
...
[24 Mar 2005 5:48] bongkeun oh
...
[24 Mar 2005 7:25] Martin Skold
Please send complete table definition.
Also your alter table operation returns two
warnings. Please do SHOW WARNINGS; to
find out what they are.
[28 Mar 2005 6:19] bongkeun oh
Thank you.
After altering table, I saw show warnings this error message printed out.

mysql> alter table tbl_pollconfig engine=NDBCLUSTER;
Query OK, 2 rows affected, 2 warnings (5.88 sec)
Records: 2  Duplicates: 0  Warnings: 0

mysql> SHOW WARNINGS;
+---------+------+---------------------------------------------------------+
| Level   | Code | Message                                                 |
+---------+------+---------------------------------------------------------+
| Warning | 1071 | Specified key was too long; max key length is 255 bytes |
| Warning | 1071 | Specified key was too long; max key length is 255 bytes |
+---------+------+---------------------------------------------------------+
2 rows in set (0.00 sec)

mysql> DESC tbl_pollconfig;
+------------------+--------------+------+-----+---------------------+----------------+
| Field            | Type         | Null | Key | Default             | Extra          |
+------------------+--------------+------+-----+---------------------+----------------+
| pollc_id         | int(11)      |      | PRI | NULL                | auto_increment |
| pollc_name       | varchar(100) |      |     |                     |                |
| pollc_tablename  | varchar(50)  |      |     |                     |                |
| pollc_desc       | varchar(50)  | YES  |     | NULL                |                |
| pollc_ispublic   | char(1)      |      |     | Y                   |                |
| pollc_grant      | varchar(4)   |      |     | 5555                |                |
| cate_code        | varchar(255) | YES  | MUL | NULL                |                |
| brand_code       | varchar(255) | YES  | MUL | NULL                |                |
| page_code        | varchar(14)  | YES  | MUL | NULL                |                |
| page_num         | varchar(3)   | YES  | MUL | NULL                |                |
| pollc_img        | varchar(100) |      |     |                     |                |
| pollc_etc01      | varchar(150) |      |     |                     |                |
| pollc_etc01_type | char(1)      |      |     | 1                   |                |
| pollc_etc01_etc  | text         | YES  |     | NULL                |                |
| pollc_etc02      | varchar(150) |      |     |                     |                |
| pollc_etc02_type | char(1)      |      |     | 1                   |                |
| pollc_etc02_etc  | text         | YES  |     | NULL                |                |
| pollc_etc03      | varchar(150) |      |     |                     |                |
| pollc_etc03_type | char(1)      |      |     | 1                   |                |
| pollc_etc03_etc  | text         | YES  |     | NULL                |                |
| pollc_etc04      | varchar(150) |      |     |                     |                |
| pollc_etc04_type | char(1)      |      |     | 1                   |                |
| pollc_etc04_etc  | text         | YES  |     | NULL                |                |
| pollc_etc05      | varchar(150) |      |     |                     |                |
| pollc_etc05_type | char(1)      |      |     | 1                   |                |
| pollc_etc05_etc  | text         | YES  |     | NULL                |                |
| pollc_publishdt  | datetime     | YES  |     | NULL                |                |
| pollc_downdt     | datetime     | YES  |     | NULL                |                |
| pollc_status     | char(1)      |      |     | R                   |                |
| pollc_regdt      | datetime     |      |     | 0000-00-00 00:00:00 |                |
| pollc_updt       | datetime     | YES  |     | NULL                |                |
+------------------+--------------+------+-----+---------------------+----------------+
31 rows in set (0.02 sec)

I think there is a problem with the length of the key, because there was no problem at innoDB,  could the length of the key be problem for NDBCLUSTER?
Is there anyway to solve this?
Hangul(korean alphbet) is in 2bytes system, Could this be the reason?

Have a nice day!
[20 Apr 2005 12:29] Martin Skold
Currently no keys longer than 225 bytes are supported.
This will be fixed in future versions.
[13 Mar 2014 13:33] Omer Barnir
This bug is not scheduled to be fixed at this time.