CREATE TABLE IF NOT EXISTS att_scalar_devboolean_rw
(
...
) ENGINE=InnoDB COMMENT='Scalar Boolean ReadWrite Values Table'
PARTITION BY RANGE COLUMNS(data_time) (
PARTITION p000 VALUES LESS THAN ('2015-01-01'),
PARTITION p2015 VALUES LESS THAN ('2016-01-01'),
PARTITION p2016 VALUES LESS THAN ('2017-01-01'),
PARTITION p2017 VALUES LESS THAN ('2018-01-01'),
PARTITION p2018 VALUES LESS THAN ('2019-01-01'),
PARTITION future VALUES LESS THAN MAXVALUE
);
CREATE TABLE IF NOT EXISTS att_scalar_devboolean_rw
(
...
) ENGINE=InnoDB COMMENT='Scalar Boolean ReadWrite Values Table'
PARTITION BY HASH(YEAR(data_time)) PARTITIONS 100;
The value of 100 is chosen by personal preference.
Please let me know, what you think of this. IMHO this simplifies usage and documentation a good deal.
I can also help with the code / documentation changes.