Maximum number of IN

When I specify 100,000 values ​​in SELECT WHERE IN(1,2,10,), only 34,464 rows are returned. If the table does not specify Engine = Columnstore, it returns 100,000 rows correctly. Is there a limit to the number of IN() in ColumnStore? (MAX 65,535?) MariaDB Version is 10.5.11.

Thank you.

Answer Answered by Roman Nozdrin in this comment.

Columnstore converts IN with literals into a tree of predicates column = VAL1 OR column = VAL2 and sends it over the network. There is an internal limit for a depth for such tree. It corresponds with a number of bytes used to encode the tree and the upper limit for the encoded tree is 65,535 bytes.

Comments

Comments loading...
Content reproduced on this site is the property of its respective owners, and this content is not reviewed in advance by MariaDB. The views, information and opinions expressed by this content do not necessarily represent those of MariaDB or any other party.