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
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
nexedi
MariaDB
Commits
b8789226
Commit
b8789226
authored
Sep 15, 2004
by
unknown
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
A fix (bug #5540: CONCAT function and 'double' type).
parent
1afd5d4d
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
17 additions
and
1 deletion
+17
-1
mysql-test/r/func_concat.result
mysql-test/r/func_concat.result
+6
-0
mysql-test/t/func_concat.test
mysql-test/t/func_concat.test
+9
-0
sql/item_strfunc.cc
sql/item_strfunc.cc
+2
-1
No files found.
mysql-test/r/func_concat.result
View file @
b8789226
...
...
@@ -26,3 +26,9 @@ FROM t1 GROUP BY new LIMIT 1;
number alpha new
1413006 idlfmv 1413006<------------------>idlfmv
drop table t1;
create table t1 (a char(4), b double, c date, d tinyint(4));
insert into t1 values ('AAAA', 105, '2003-03-01', 1);
select * from t1 where concat(A,C,B,D) = 'AAAA2003-03-011051';
a b c d
AAAA 105 2003-03-01 1
drop table t1;
mysql-test/t/func_concat.test
View file @
b8789226
...
...
@@ -25,3 +25,12 @@ FROM t1 GROUP BY new LIMIT 1;
SELECT
number
,
alpha
,
CONCAT_WS
(
'<------------------>'
,
number
,
alpha
)
AS
new
FROM
t1
GROUP
BY
new
LIMIT
1
;
drop
table
t1
;
#
# Bug #5540: a problem with double type
#
create
table
t1
(
a
char
(
4
),
b
double
,
c
date
,
d
tinyint
(
4
));
insert
into
t1
values
(
'AAAA'
,
105
,
'2003-03-01'
,
1
);
select
*
from
t1
where
concat
(
A
,
C
,
B
,
D
)
=
'AAAA2003-03-011051'
;
drop
table
t1
;
sql/item_strfunc.cc
View file @
b8789226
...
...
@@ -289,7 +289,8 @@ String *Item_func_concat::val_str(String *str)
str
->
copy
(
*
res
);
str
->
append
(
*
res2
);
}
res
=
str
;
res
=
str
;
use_as_buff
=
&
tmp_value
;
}
else
if
(
res
==
&
tmp_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