[MDEV-5932] Wrong result on CREATE TABLE .. AS SELECT .. <TokuDB table> Created: 2014-03-22 Updated: 2014-05-06 Resolved: 2014-05-06 |
|
| Status: | Closed |
| Project: | MariaDB Server |
| Component/s: | None |
| Affects Version/s: | 5.5.36, 10.0.9 |
| Fix Version/s: | 5.5.38, 10.0.11 |
| Type: | Bug | Priority: | Minor |
| Reporter: | Elena Stepanova | Assignee: | Unassigned |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | tokudb, upstream | ||
| Description |
|
The issue is also reproducible on TokuDB builds of MySQL-5.5.36 and MariaDB 5.5.36 (but not reproducible without TokuDB). The result of SELECT with NOT IN ( .. NULL .. ) clause differs from the result of CREATE TABLE .. SELECT (with the same query). Test case:
Results (for MySQL-5.5.36-TokuDB):
|
| Comments |
| Comment by Rich Prohaska [ 2014-04-02 ] |
|
TokuDB generates an empty result set for a select with sub-select, but generated a non-empty result set for the same query when creating a new table. The result set should be the same in both cases. What is going on here? InnoDB computes an empty result set for both cases. I traced the problem to the tokudb::index_read function. The tokudb::index_read does not handle the null byte key prefix. Unfortunately, I do not understand how the null byte (byte 0) in the key handed to the ::index_read function is supposed to work. Most of the time, the value of this byte is 0. Sometimes it is set to 1. How should the storage engine work WRT this? BTW, this problem exists with TokuDB in MySQL 5.5.36, MySQL 5.6.16. I have not been able to consistently see this on MariaDB 5.5.36 for some reason. In any case, I am interested in how the handler's index_read function is supposed to process the null byte. |
| Comment by Rich Prohaska [ 2014-04-28 ] |
|
fixed in tokudb 7.1.6 |