Details
-
Bug
-
Status: Closed (View Workflow)
-
Major
-
Resolution: Won't Do
-
1.1.6
-
Ubuntu 18.04.1 LTS
10.2.17-MariaDB
Description
A very long IN clause is causing wrong results. My testcase works fine with INNODB engine though.
Steps to reproduce (attachment would be too long):
CREATE TABLE IF NOT EXISTS numbers (seq INT) ENGINE=COLUMNSTORE; |
INSERT INTO numbers SELECT seq FROM seq_1_to_2015667; |
SELECT count(*),max(seq) FROM numbers; #shows 2015667 |
SELECT * FROM numbers WHERE seq IN (SELECT seq FROM seq_1_to_2015667); |
Resultset counts 2015667 records.
Now the weird part: Generate a comma separated list of all numbers, e.g.
SELECT GROUP_CONCAT(seq) FROM seq_1_to_2015667; |
and send them explicitly in the query.
SELECT * FROM numbers WHERE seq IN (1,2,3,4,...many numbers...,2015666,2015667); |
Resultset counts 49587 records.
On INNODB, this is working fine. The second resultset counts 2015667 records, as expected. I've made the following changes to the config:
[mysqld]
|
tmp_table_size=4294967295
|
max_heap_table_size=4294966272
|
skip-log-bin
|
disable-log-bin
|
max_allowed_packet=1073741824
|
max_length_for_sort_data=8388608
|
max_long_data_size=4294967295
|
max_sort_length=8388608
|
I'm suspecting some undocumented limit or a bug.