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
009bcc74
Commit
009bcc74
authored
Oct 27, 2005
by
jimw@mysql.com
Browse files
Options
Browse Files
Download
Plain Diff
Merge mysql.com:/home/jimw/my/mysql-4.1-clean
into mysql.com:/home/jimw/my/mysql-5.0-clean
parents
74b8b449
7a8bd252
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
17 additions
and
0 deletions
+17
-0
mysql-test/r/func_math.result
mysql-test/r/func_math.result
+6
-0
mysql-test/t/func_math.test
mysql-test/t/func_math.test
+10
-0
sql/item_func.cc
sql/item_func.cc
+1
-0
No files found.
mysql-test/r/func_math.result
View file @
009bcc74
...
...
@@ -170,6 +170,12 @@ insert into t1 values (1);
select rand(i) from t1;
ERROR HY000: Incorrect arguments to RAND
drop table t1;
create table t1 (a varchar(90), ts datetime not null, index (a)) engine=innodb default charset=utf8;
insert into t1 values ('http://www.foo.com/', now());
select a from t1 where a='http://www.foo.com/' order by abs(timediff(ts, 0));
a
http://www.foo.com/
drop table t1;
set sql_mode='traditional';
select ln(-1);
ln(-1)
...
...
mysql-test/t/func_math.test
View file @
009bcc74
...
...
@@ -116,6 +116,16 @@ insert into t1 values (1);
select
rand
(
i
)
from
t1
;
drop
table
t1
;
#
# Bug #14009: use of abs() on null value causes problems with filesort
#
# InnoDB is required to reproduce the fault, but it is okay if we default to
# MyISAM when testing.
create
table
t1
(
a
varchar
(
90
),
ts
datetime
not
null
,
index
(
a
))
engine
=
innodb
default
charset
=
utf8
;
insert
into
t1
values
(
'http://www.foo.com/'
,
now
());
select
a
from
t1
where
a
=
'http://www.foo.com/'
order
by
abs
(
timediff
(
ts
,
0
));
drop
table
t1
;
# End of 4.1 tests
#
...
...
sql/item_func.cc
View file @
009bcc74
...
...
@@ -636,6 +636,7 @@ void Item_func_num1::fix_num_length_and_dec()
{
decimals
=
args
[
0
]
->
decimals
;
max_length
=
args
[
0
]
->
max_length
;
maybe_null
=
1
;
}
...
...
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