1
0
mirror of https://github.com/MariaDB/server.git synced 2025-07-29 05:21:33 +03:00

Bug #55565: debug assertion when ordering by expressions with user

variable assignments

The assert() that is firing is checking if expressions that can't be
null return a NULL when evaluated.
MAKEDATE() function can return NULL if the second argument is 
less then or equal to 0. Thus its nullability depends not only on 
the nullability of its arguments but also on their values.
Fixed by (overoptimistically) setting MAKEDATE() to be nullable 
despite the nullability of its arguments.
Test added.
Had to update one test result to reflect the metadata change.
This commit is contained in:
Georgi Kodinov
2010-08-13 16:05:46 +03:00
parent 41cfa3e769
commit 8b25c0e4dc
4 changed files with 22 additions and 1 deletions

View File

@ -194,7 +194,7 @@ date("1997-12-31 23:59:59.000001") as f8,
time("1997-12-31 23:59:59.000001") as f9;
describe t1;
Field Type Null Key Default Extra
f1 date NO 0000-00-00
f1 date YES NULL
f2 datetime YES NULL
f3 time YES NULL
f4 time YES NULL