[MDEV-21195] INSERT chooses wrong partition for RANGE partitioning by DECIMAL column Created: 2019-12-02 Updated: 2020-02-03 Resolved: 2020-02-03 |
|
| Status: | Closed |
| Project: | MariaDB Server |
| Component/s: | Partitioning |
| Affects Version/s: | 10.3, 10.4 |
| Fix Version/s: | 10.3.23, 10.4.13 |
| Type: | Bug | Priority: | Major |
| Reporter: | Elena Stepanova | Assignee: | Aleksey Midenkov |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Issue Links: |
|
||||||||
| Description |
|
Starting from this revision, MariaDB 10.3+ allows partitioning by range of a decimal column:
However, the behavior looks strange.
or another way to put it,
Obviously, it temporarily rounds the value before finding a partition, but I don't think the outcome is reasonable. I couldn't find any documentation, either in MariaDB KB or in the version of SQL standard which I have access to on how it should really behave (and MySQL doesn't support it even in 8.0, so can't compare with it either). |
| Comments |
| Comment by Alexander Barkov [ 2020-01-29 ] | |||||||||||||||||||
|
Hi midenok, I think your patch does not fix the following scenarios:
| |||||||||||||||||||
| Comment by Alexander Barkov [ 2020-01-29 ] | |||||||||||||||||||
|
I don't think we need another virtual method val_int(decimal_round_mode round_type). |