This repository was archived by the owner on Jul 26, 2022. It is now read-only.
This repository was archived by the owner on Jul 26, 2022. It is now read-only.
Support index-only scans for collations other than _bin #25
Closed
Description
Currently, index-only scans are supported for
- numeric columns
- varchar columns with BINARY, latin1_bin, utf8_bin collation.
for other collations (eg. case-insensitive, _ci collations), index-only scans are not supported. The reason for this is that is not possible to restore the original column value mem-comparable key. For example, in latin_general_ci both 'foo', 'Foo', and 'FOO' have mem-comparable form 'FOO'.
A possible solution could work like this:
- In addition to value->mem_comparable_form function, develop value->(mem_comparable_form, restore_data) function. This is easy for some charsets.
- store restore_data in RocksDB's value part of the key-value pair. We already used to store information about VARCHAR field length there, but now the value part is unused.
See also:
- Efficient VARCHAR storage for keys: https://github.com/mariadb-corporation/webscalesql-5.6-rocksdb/issues/4
- Covering index is disabled if not using *_bin collation: https://github.com/mariadb-corporation/webscalesql-5.6-rocksdb/issues/13