Details
-
Bug
-
Status: Open (View Workflow)
-
Major
-
Resolution: Unresolved
-
10.3, 10.4, 10.5, 10.6, 10.7
-
None
Description
CREATE OR REPLACE TABLE t (c VARCHAR(16) COMPRESSED) ENGINE=MyISAM CHARACTER SET utf32; |
INSERT INTO t VALUES ('n'); |
ALTER TABLE t FORCE; |
SELECT c, HEX(c) FROM t; |
ALTER IGNORE TABLE t FORCE; |
SELECT c, HEX(c) FROM t; |
ALTER fails with
10.3 333d6c30 |
MariaDB [test]> ALTER TABLE t FORCE; |
ERROR 1265 (01000): Data truncated for column 'c' at row 1 |
for no good reason, as far as I can tell.
ALTER IGNORE does what the error/warning threatens to and truncates the data:
MariaDB [test]> SELECT c, HEX(c) FROM t; |
+------+----------+ |
| c | HEX(c) |
|
+------+----------+ |
| n | 0000006E |
|
+------+----------+ |
1 row in set (0.000 sec) |
|
MariaDB [test]> ALTER IGNORE TABLE t FORCE; |
Query OK, 1 row affected, 1 warning (0.006 sec)
|
Records: 1 Duplicates: 0 Warnings: 1
|
|
MariaDB [test]> SELECT c, HEX(c) FROM t; |
+------+--------+ |
| c | HEX(c) |
|
+------+--------+ |
| ?? | 000000 |
|
+------+--------+ |
1 row in set (0.001 sec) |