LIST and LIST COLUMNS partitioning

LIST partitioning is similar to RANGE partitioning, where each partition is defined and selected based on the membership of a column value in one of a set of value lists, rather than in one of a set of contiguous ranges of values.

You need to define it by PARTITION BY LIST(<expr>), where expr is a column value or an expression based on a column value and returning an integer value.

Partition definition contains VALUES IN (<value_list>), where value_list is a comma-separated list of integers rather than VALUES LESS THAN (<value>).

If you wish to use data types other than integers, you can use LIST COLUMNS.

Unlike the case with RANGE partitioning, there is no catch-all such as MAXVALUE; all expected values ...

Get MySQL 8 Cookbook now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.