<p>MySQL raises ER_MAXVALUE_IN_VALUES_IN when the MAXVALUE keyword is included inside a VALUES IN partition list, which is not allowed.</p>
<p>MySQL Error 1656: ER_MAXVALUE_IN_VALUES_IN occurs when MAXVALUE is placed inside a VALUES IN partition definition. Remove MAXVALUE or switch to RANGE partitioning to resolve the issue.</p>
Cannot use MAXVALUE as value in VALUES IN
MySQL throws error code 1656 with message Cannot use MAXVALUE as value in VALUES IN when a VALUES IN partition list contains the MAXVALUE keyword. MAXVALUE is reserved for RANGE partitioning, so using it inside VALUES IN is a syntax violation.
The error stops CREATE TABLE or ALTER TABLE statements from executing, leaving the table unchanged until the partition definition is corrected.
VALUES IN partitions implement list partitioning, which explicitly enumerates discrete values. MAXVALUE functions as an upper catch-all boundary in range partitioning. Combining the two concepts would blur partition boundaries, so MySQL blocks the operation.
Failed DDL statements delay deployments, migrations and ETL jobs. Automation pipelines that expect partitions to exist may break, leading to missing data or performance regressions.
Developers migrating from RANGE to LIST partitioning often copy MAXVALUE by mistake.
Tutorial or StackOverflow snippets meant for RANGE partitions are reused verbatim inside a VALUES IN clause.
Code that builds partition DDL constructs MAXVALUE for all strategies, inserting it where it is illegal.
Raised when MAXVALUE appears alongside explicit VALUES LESS THAN limits in RANGE partitioning.
Occurs if two partitions define overlapping value ranges.
Triggered when the VALUES IN list contains illegal or duplicate elements.
No. If you need both concepts, create separate tables or migrate entirely to RANGE partitioning.
All maintained MySQL branches from 5.1 onward enforce the rule, including 5.7, 8.0 and 8.1.
Yes. Galaxy's SQL editor parses partition clauses in real time and flags illegal MAXVALUE usage before the statement runs.
Correct partition alignment improves pruning and query speed. Using invalid definitions prevents any performance gain.