Details
-
Bug
-
Status: Closed (View Workflow)
-
Major
-
Resolution: Fixed
-
5.5(EOL), 10.0(EOL), 10.1(EOL)
-
None
Description
Currently there is no an easy way to distinguish between an old DECIMAL data type the new DECIMAL which was introduced in 5.5
The old column type is not automatically converted to the new data type on upgrade because of some incompatibility in the supported precision and scale ranges.
Some users still have old DECIMAL in their 10.0 installations after a set upgrades made in different years (to 5.0, 5.1, 5.5 and finally to 10.0) and even don't know about presence of such column!
We will add the "/*old*/" comment into the column type.
- In INFORMATION_SCHEMA:
MariaDB [test]> SELECT DATA_TYPE, COLUMN_TYPE FROM INFORMATION_SCHEMA.COLUMNS WHERE COLUMN_NAME='a';
+-----------+----------------------+
| DATA_TYPE | COLUMN_TYPE |
+-----------+----------------------+
| decimal | decimal(10,2)/*old*/ |
+-----------+----------------------+
- In SHOW COLUMNS:
MariaDB [test]> SHOW COLUMNS FROM dec102;
+-------+----------------------+------+-----+---------+-------+
| Field | Type | Null | Key | Default | Extra |
+-------+----------------------+------+-----+---------+-------+
| a | decimal(10,2)/*old*/ | YES | | NULL | |
+-------+----------------------+------+-----+---------+-------+
- SHOW CREATE TABLE
MariaDB [test]> SHOW CREATE TABLE dec102;
+--------+--------------------------------------------------------------------------------------------------------+
| Table | Create Table |
+--------+--------------------------------------------------------------------------------------------------------+
| dec102 | CREATE TABLE `dec102` (
`a` decimal(10,2)/*old*/ DEFAULT NULL
) ENGINE=MyISAM DEFAULT CHARSET=latin1 |
+--------+--------------------------------------------------------------------------------------------------------+
Attachments
Issue Links
- blocks
-
MDEV-7628 Row-based replication of old DECIMAL to new DECIMAL
- Stalled