[MDEV-10252] Row count in 'out of range' warnings is off Created: 2016-06-19 Updated: 2017-09-18 |
|
| Status: | Open |
| Project: | MariaDB Server |
| Component/s: | Server |
| Affects Version/s: | 10.1, 10.2 |
| Fix Version/s: | 10.2 |
| Type: | Bug | Priority: | Major |
| Reporter: | Elena Stepanova | Assignee: | Sergei Golubchik |
| Resolution: | Unresolved | Votes: | 0 |
| Labels: | None | ||
| Description |
|
Consider the following scenario:
The first INSERT above is inside limits and does not produce any warnings.
Apparently meaning that it's at the first inserted row.
Maybe it means to say that the row it complains about is to become the 2nd row in the table, so it's not technically incorrect, as long as it is an expected change. Either way, the row count becomes 2. But the 3rd INSERT is a problem. Before 10.2, it said
which we can interpret as a to-be-the-3rd-row in the table. However, in 10.2 it's
which just does not have a plausible explanation from the user's perspective. |
| Comments |
| Comment by Alexander Barkov [ 2017-05-24 ] | ||||||||
|
Elena, wrong row number in error message is not in my area of expertise. Can you please reassign it to somebody else? Thanks. | ||||||||
| Comment by Alexander Barkov [ 2017-05-25 ] | ||||||||
|
Some more observations: If I change the data type from tinytint to decimal(1,0):
In 10.0 it correctly reports:
In 10.2 it erroneously reports:
This makes me feel that this problem did not apper after Another reason to think that | ||||||||
| Comment by Sergei Golubchik [ 2017-06-22 ] | ||||||||
|
It's in 10.1 all right. The warning does not tell, what row it will become in the table, compare with:
| ||||||||
| Comment by Sergei Golubchik [ 2017-09-18 ] | ||||||||
|
The logic is fairly convoluted and, well, doesn't look very logical to me. It'd like to define and implement simple and consistent rule for this row number, but it'd be too big a change for 10.1. |