Commit Graph

6 Commits

Author SHA1 Message Date
Yatsishin Ilya
a25fa1996b fix style checks 2020-12-29 17:57:12 +03:00
Ivan
315ff4f0d9
ANTLR4 Grammar for ClickHouse and new parser (#11298) 2020-12-04 05:15:44 +03:00
Alexey Milovidov
1a487f88d6 Minor changes 2020-08-03 00:24:16 +03:00
Nicolae Vartolomei
c95d09aed0 Add a test to cover non-const tuple elemenets (just in case) 2020-07-01 11:01:47 +01:00
Nicolae Vartolomei
b1d2d55cba Add explicit test for a case where AST hashes collide for different prepared sets 2020-06-30 18:19:20 +01:00
Nicolae Vartolomei
8f1845185e Try fix pk in tuple performance
Possible approach for fixing #10574

The problem is that prepared sets are built correctly, it is a hash map of key -> set
where key is a hash of AST and list of data types (when we a list of
tuples of literals).

However, when the key is built from the index to try and find if there
exists a prepared set that would match it looks for data types of the
primary key (see how data_types is populated) because the primary key
has only one field (v in my example) it can not find the prepared set.

The patch looks for any prepared indexes where data types match for the
subset of fields found in primary key, we are not interested in other
fields anyway for the purpose of primary key pruning.
2020-06-30 16:33:38 +01:00