Details
-
Bug
-
Status: Closed (View Workflow)
-
Critical
-
Resolution: Fixed
-
23.02.1, 23.02.3
-
MariaDB 10.5.10, Columnstore 5.5.2; MariaDB 10.5.18, Columnstore 5.6.8; RHEL 8.2 and RHEL 8.5
-
2023-8, 2023-10
Description
The attached query ("crashing_select...sql") on the attached Columnstore table (see "create_tables_...sql") using the exported data ("ebi_es_op_or...csv") immediately crashes Columnstore engine when executed.
Result: ERROR 2013 (HY000) at line 1: Lost connection to MySQL server during query
When the table is InnoDB (suffix "_innodb") it works flawlessly ("working_select...sql")
Side note: query is generated by a third-party BI tool, where we have no possibility to change the way it generates the SQL queries to avoid such big IN-clauses.
TBD: solution :
.....
The currently proposed solution: Introduction of a new runtime variable defined as
MariaDB [test]> show variables like 'columnstore_max_in%';
--------------------------------------------+
Variable_name | Value |
--------------------------------------------+
columnstore_max_in_limit_query_length | 1000 |
--------------------------------------------+
1 row in set (0.001 sec)
which is a limit for the maximum length of an IN query measure in number of values .
If the query is longer, an error is signaled:
ERROR 1178 (42000): The storage engine for the table doesn't support long in clauses. Query exceeds max_in_limit_query_length threshold: consider changing the value via SET @var_name := value;
If there are multiple IN clauses in query, the limit is checked against the longest.
The default value is a subject to be determined, right now it is 6000 items.
Right now this has a possible side effect of possibly limiting some of the OR clauses as well, but I have not managed to find one.
Attachments
Issue Links
- is duplicated by
-
MCOL-5321 MCS plugin crashes MDB runtime for IN with a long(>4000) list of literals
- Closed