[MDEV-15340] Wrong result HOUR(case_expression_with_time_and_datetime) Created: 2018-02-17 Updated: 2018-08-03 Resolved: 2018-02-19 |
|
| Status: | Closed |
| Project: | MariaDB Server |
| Component/s: | Temporal Types |
| Affects Version/s: | 10.0, 10.1, 10.2, 10.3 |
| Fix Version/s: | 10.3.5 |
| Type: | Bug | Priority: | Major |
| Reporter: | Alexander Barkov | Assignee: | Alexander Barkov |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Issue Links: |
|
||||||||||||||||||||
| Description |
|
The result for hc is wrong. It returns HOURS() of the first argument of COALESCE() before its conversion to DATETIME. The expected result is to return hours after conversion, i,e. 8, like the hour part in the first column c. The same problem is repeatable with CASE and its abbreviations:
|
| Comments |
| Comment by Alexander Barkov [ 2018-02-19 ] | ||||||||||
|
A related problem:
The result for c3 and c4 is wrong. The expected result is NULL for all four columns. | ||||||||||
| Comment by Alexander Barkov [ 2018-02-19 ] | ||||||||||
|
Pushed to bb-10.2-ext |