[MDEV-16888] Add virtual Type_handler::cond_notnull_field_isnull_to_field_eq_zero() Created: 2018-08-03 Updated: 2018-08-03 Resolved: 2018-08-03 |
|
| Status: | Closed |
| Project: | MariaDB Server |
| Component/s: | Data types |
| Fix Version/s: | 10.4.0 |
| Type: | Task | Priority: | Major |
| Reporter: | Alexander Barkov | Assignee: | Alexander Barkov |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Issue Links: |
|
||||||||
| Description |
|
The code rewriting "datetime_field IS NULL" to "datetime_field='0000-00-00'" has tests for field_type():
This is not friendly to new data types. We'll remove these tests and add a new method in Type_handler_instead:
and override it for Type_handler_date_common and Type_handler_datetime_common to return true. |