News for hackers. Stuff that matters.
Re:My Notes on Gitlab's Postgres Schema Design (2022) by zX41ZdbW on Sunday February 18, 2024 @08:14PM (#39425231)
The LowCardinality data type does not require the whole set of values to have a low cardinality. It benefits when the values have locally low cardinality. For example, if the number of unique values in `repo_name` is a hundred million, but for every million consecutive values, there are only ten thousand unique, it will give a great speed-up.
Re:My Notes on Gitlab's Postgres Schema Design (2022) by zx8080 on Thursday February 22, 2024 @06:35PM (#39474871)
> LowCardinality data type does not require the whole set of values to have a low cardinality.

Don't mislead others. It's not true unless low_cardinality_max_dictionary_size is set to some other value than the default one: 8192.

It does not work well for hundred million values.