[MDEV-12571] Incorrect number of affected rows using Connect engine; Created: 2017-04-24 Updated: 2017-05-11 Resolved: 2017-05-11 |
|
| Status: | Closed |
| Project: | MariaDB Server |
| Component/s: | Storage Engine - Connect |
| Affects Version/s: | 10.1.22 |
| Fix Version/s: | N/A |
| Type: | Bug | Priority: | Minor |
| Reporter: | Alice Sherepa | Assignee: | Olivier Bertrand |
| Resolution: | Won't Fix | Votes: | 0 |
| Labels: | None | ||
| Description |
|
Example below shows 6 rows affected, but should be 3.
|
| Comments |
| Comment by Olivier Bertrand [ 2017-05-10 ] |
|
When doing delete all rows, MariaDB tries to get the number of lines by calling info and the storage engine replies by calling Cardinality. Because this information is often used just to optimize query performance, returning an estimate is generally correct. For many table types, returning an exact number of rows can be a long process, this is why Connect returns an estimate by default. Setting the connect_exact_info to ON currently works only for info commands. Do you think I should also do it for DELETE? |
| Comment by Elena Stepanova [ 2017-05-11 ] |
|
No, I think we'd better leave it as is for now. Until somebody from real world comes with a compelling reason why the accurate number is very important, I think we should prioritize performance over it. We can always get back to it later. |