stonedb
stonedb copied to clipboard
bug: update float type data, return NULL
Have you read the Contributing Guidelines on issues?
- [X] I have read the Contributing Guidelines on issues.
Please confirm if bug report does NOT exists already ?
- [X] I confirm there is no existing issue for this
Describe the problem
mysql> create table t3 (
-> col_signed tinyint,
-> col_unsigned tinyint unsigned
-> );
Query OK, 0 rows affected (0.02 sec)
mysql> insert into t3 values (123,124);
Query OK, 1 row affected (0.00 sec)
mysql> ALTER TABLE t3 ADD COLUMN col_float_signed FLOAT;
Query OK, 0 rows affected (0.09 sec)
Records: 0 Duplicates: 0 Warnings: 0
mysql> UPDATE t3 SET col_float_signed=col_signed + 0.1;
Query OK, 1 row affected (0.01 sec)
Rows matched: 1 Changed: 1 Warnings: 0
mysql> select * from t3;
+------------+--------------+------------------+
| col_signed | col_unsigned | col_float_signed |
+------------+--------------+------------------+
| 123 | 124 | NULL |
+------------+--------------+------------------+
1 row in set (0.00 sec)
Expected behavior
mysql> select * from t3;
+------------+--------------+------------------+
| col_signed | col_unsigned | col_float_signed |
+------------+--------------+------------------+
| 123 | 124 | 123.1 |
+------------+--------------+------------------+
1 row in set (0.00 sec)
How To Reproduce
No response
Environment
root@ub01:~# /stonedb57/install//bin/mysqld --version
/stonedb57/install//bin/mysqld Ver 5.7.36-StoneDB-v1.0.3 for Linux on x86_64 (build-)
build information as follow:
Repository address: https://github.com/stoneatom/stonedb.git:stonedb-5.7-dev
Branch name: stonedb-5.7-dev
Last commit ID: 1fa5661e4
Last commit time: Date: Thu Mar 23 20:19:17 2023 +0800
Build time: Date: Wed Mar 29 10:31:02 CST 2023
Are you interested in submitting a PR to solve the problem?
- [ ] Yes, I will!