diff options
author | unknown <igor@rurik.mysql.com> | 2005-06-15 08:27:33 -0700 |
---|---|---|
committer | unknown <igor@rurik.mysql.com> | 2005-06-15 08:27:33 -0700 |
commit | 1575df007448a62bec690e6842cd576cc96a3cb5 (patch) | |
tree | 72b3677130fa85e1a40e4eabe5bd4460ee20308c /mysql-test/r/cast.result | |
parent | ad57284c6925fe19c182e5b43562e131e1297d7b (diff) | |
download | mariadb-git-1575df007448a62bec690e6842cd576cc96a3cb5.tar.gz |
cast.result, cast.test:
Added test case for bug #11283.
field.h, field.cc:
Fixed bug #11283: wrong conversion from varchar to decimal.
Added methods Field_string::val_decimal,
Field_varstring::val_decimal, Field_blob::val_decimal.
They are not inherited from the base class Field_longstr
anymore.
sql/field.cc:
Fixed bug #11283: wrong conversion from varchar to decimal.
Added methods Field_string::val_decimal,
Field_varstring::val_decimal, Field_blob::val_decimal.
They are not inherited from the base class Field_longstr
anymore.
sql/field.h:
Fixed bug #11283: wrong conversion from varchar to decimal.
Added methods Field_string::val_decimal,
Field_varstring::val_decimal, Field_blob::val_decimal.
They are not inherited from the base class Field_longstr
anymore.
mysql-test/t/cast.test:
Added test case for bug #11283.
mysql-test/r/cast.result:
Added test case for bug #11283.
Diffstat (limited to 'mysql-test/r/cast.result')
-rw-r--r-- | mysql-test/r/cast.result | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/mysql-test/r/cast.result b/mysql-test/r/cast.result index 6dc608a9289..fe3a1b0b606 100644 --- a/mysql-test/r/cast.result +++ b/mysql-test/r/cast.result @@ -344,3 +344,11 @@ select cast(s1 as decimal(7,2)) from t1; cast(s1 as decimal(7,2)) 111111.00 drop table t1; +CREATE TABLE t1 (v varchar(10), tt tinytext, t text, +mt mediumtext, lt longtext); +INSERT INTO t1 VALUES ('1.01', '2.02', '3.03', '4.04', '5.05'); +SELECT CAST(v AS DECIMAL), CAST(tt AS DECIMAL), CAST(t AS DECIMAL), +CAST(mt AS DECIMAL), CAST(lt AS DECIMAL) from t1; +CAST(v AS DECIMAL) CAST(tt AS DECIMAL) CAST(t AS DECIMAL) CAST(mt AS DECIMAL) CAST(lt AS DECIMAL) +1.01 2.02 3.03 4.04 5.05 +DROP TABLE t1; |