Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
M
mariadb
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
mariadb
Commits
6167f61f
Commit
6167f61f
authored
Mar 07, 2005
by
marko@hundin.mysql.fi
Browse files
Options
Browse Files
Download
Plain Diff
Merge marko@bk-internal.mysql.com:/home/bk/mysql-5.0
into hundin.mysql.fi:/home/marko/mysql-5.0
parents
cae5d4e9
fbbb58c6
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
11 additions
and
2 deletions
+11
-2
mysql-test/r/cast.result
mysql-test/r/cast.result
+6
-0
mysql-test/r/func_group.result
mysql-test/r/func_group.result
+0
-1
mysql-test/t/cast.test
mysql-test/t/cast.test
+5
-0
sql/field.cc
sql/field.cc
+0
-1
No files found.
mysql-test/r/cast.result
View file @
6167f61f
...
@@ -203,3 +203,9 @@ cast(@v1 as decimal(22, 2))
...
@@ -203,3 +203,9 @@ cast(@v1 as decimal(22, 2))
select cast(-1e18 as decimal(22,2));
select cast(-1e18 as decimal(22,2));
cast(-1e18 as decimal(22,2))
cast(-1e18 as decimal(22,2))
-1000000000000000000.00
-1000000000000000000.00
create table t1(s1 time);
insert into t1 values ('11:11:11');
select cast(s1 as decimal(7,2)) from t1;
cast(s1 as decimal(7,2))
111111.00
drop table t1;
mysql-test/r/func_group.result
View file @
6167f61f
...
@@ -855,7 +855,6 @@ select col1,sum(col1),max(col1),min(col1) from t1 group by col1;
...
@@ -855,7 +855,6 @@ select col1,sum(col1),max(col1),min(col1) from t1 group by col1;
col1 sum(col1) max(col1) min(col1)
col1 sum(col1) max(col1) min(col1)
5.000000000010 10.000000000020 5.000000000010 5.000000000010
5.000000000010 10.000000000020 5.000000000010 5.000000000010
DROP TABLE t1;
DROP TABLE t1;
CREATE TABLE t1(
CREATE TABLE t1(
id int PRIMARY KEY,
id int PRIMARY KEY,
a int,
a int,
...
...
mysql-test/t/cast.test
View file @
6167f61f
...
@@ -126,3 +126,8 @@ select cast(cast('1.2' as decimal(3,2)) as signed);
...
@@ -126,3 +126,8 @@ select cast(cast('1.2' as decimal(3,2)) as signed);
set
@
v1
=
1
e18
;
set
@
v1
=
1
e18
;
select
cast
(
@
v1
as
decimal
(
22
,
2
));
select
cast
(
@
v1
as
decimal
(
22
,
2
));
select
cast
(
-
1
e18
as
decimal
(
22
,
2
));
select
cast
(
-
1
e18
as
decimal
(
22
,
2
));
create
table
t1
(
s1
time
);
insert
into
t1
values
(
'11:11:11'
);
select
cast
(
s1
as
decimal
(
7
,
2
))
from
t1
;
drop
table
t1
;
sql/field.cc
View file @
6167f61f
...
@@ -626,7 +626,6 @@ int Field_str::store_decimal(const my_decimal *d)
...
@@ -626,7 +626,6 @@ int Field_str::store_decimal(const my_decimal *d)
my_decimal
*
Field_str
::
val_decimal
(
my_decimal
*
decimal_value
)
my_decimal
*
Field_str
::
val_decimal
(
my_decimal
*
decimal_value
)
{
{
DBUG_ASSERT
(
result_type
()
==
INT_RESULT
);
longlong
nr
=
val_int
();
longlong
nr
=
val_int
();
int2my_decimal
(
E_DEC_FATAL_ERROR
,
nr
,
0
,
decimal_value
);
int2my_decimal
(
E_DEC_FATAL_ERROR
,
nr
,
0
,
decimal_value
);
return
decimal_value
;
return
decimal_value
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment