Details
-
Bug
-
Status: Open (View Workflow)
-
Minor
-
Resolution: Unresolved
-
5.4.3, 6.1.1
-
None
Description
This is similar to MCOL-4420, however for VARCHAR input instead of DECIMAL input.
DROP TABLE IF EXISTS t1; |
CREATE TABLE t1 (a VARCHAR(10)) ENGINE=MyISAM; |
INSERT INTO t1 VALUES ('1.9'); |
SELECT TIMESTAMP'2001-01-01 00:00:00' + INTERVAL a SECOND FROM t1; |
+-----------------------------------------------------+
|
| TIMESTAMP'2001-01-01 00:00:00' + INTERVAL a SECOND |
|
+-----------------------------------------------------+
|
| 2001-01-01 00:00:01.900000 |
|
+-----------------------------------------------------+
|
DROP TABLE IF EXISTS t1; |
CREATE TABLE t1 (a VARCHAR(10)) ENGINE=COLUMNSTORE; |
INSERT INTO t1 VALUES ('1.9'); |
SELECT TIMESTAMP'2001-01-01 00:00:00' + INTERVAL a SECOND FROM t1; |
+-----------------------------------------------------+
|
| TIMESTAMP'2001-01-01 00:00:00' + INTERVAL a SECOND |
|
+-----------------------------------------------------+
|
| 2001-01-01 00:00:01.000000 |
|
+-----------------------------------------------------+
|
Notice, unlike MyISAM, with ColumnStore the fractional part is set to zeros instead of '.900000'.