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
0ff1b80b
Commit
0ff1b80b
authored
Oct 06, 2007
by
tnurnberg@sin.intern.azundris.com
Browse files
Options
Browse Files
Download
Plain Diff
Merge tnurnberg@bk-internal.mysql.com:/home/bk/mysql-5.1-maint
into sin.intern.azundris.com:/home/tnurnberg/31253/51-31253
parents
e4ba79d2
d4213572
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
20 additions
and
0 deletions
+20
-0
mysql-test/r/type_datetime.result
mysql-test/r/type_datetime.result
+9
-0
mysql-test/t/type_datetime.test
mysql-test/t/type_datetime.test
+10
-0
sql/item.cc
sql/item.cc
+1
-0
No files found.
mysql-test/r/type_datetime.result
View file @
0ff1b80b
...
...
@@ -427,6 +427,15 @@ f1
Warnings:
Warning 1292 Incorrect datetime value: '2007010100000' for column 'f1' at row 1
drop table t1;
create table t1 (f1 time);
insert into t1 set f1 = '45:44:44';
insert into t1 set f1 = '15:44:44';
select * from t1 where (convert(f1,datetime)) != 1;
f1
15:44:44
Warnings:
Warning 1292 Incorrect datetime value: '0000-00-00 45:44:44'
drop table t1;
set @org_mode=@@sql_mode;
create table t1 (da date default '1962-03-03 23:33:34', dt datetime default '1962-03-03');
Warnings:
...
...
mysql-test/t/type_datetime.test
View file @
0ff1b80b
...
...
@@ -283,6 +283,16 @@ select * from t1 where f1 between 2002010 and 20070101000000;
select
*
from
t1
where
f1
between
20020101
and
2007010100000
;
drop
table
t1
;
#
# Bug #31253: crash comparing datetime to double
# Should return 1st row only. Crashes if NULL propagation fails.
#
create
table
t1
(
f1
time
);
insert
into
t1
set
f1
=
'45:44:44'
;
insert
into
t1
set
f1
=
'15:44:44'
;
select
*
from
t1
where
(
convert
(
f1
,
datetime
))
!=
1
;
drop
table
t1
;
#
# Test of storing datetime into date fields
#
...
...
sql/item.cc
View file @
0ff1b80b
...
...
@@ -272,6 +272,7 @@ my_decimal *Item::val_decimal_from_date(my_decimal *decimal_value)
if
(
get_date
(
&
ltime
,
TIME_FUZZY_DATE
))
{
my_decimal_set_zero
(
decimal_value
);
null_value
=
1
;
// set NULL, stop processing
return
0
;
}
return
date2my_decimal
(
&
ltime
,
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