Informix Error -25812: The difference between the old and new transition values must be a multiple of the interval value.
Cause and resolution
The difference between the old and new transition values must be a multiple of the interval value.
If altering the fragmentation scheme changes the transition value, and the table or index has interval fragments, then the difference between the old and new transition values must be a multiple of the interval value.
For example, consider a table with following schema:
CREATE TABLE employee (emp_id INTEGER, emp_name CHAR(64), ssn CHAR(12), basepay FLOAT, varpay FLOAT, dept_id SMALLINT, hire_date DATE) FRAGMENT BY RANGE(emp_id) INTERVAL(3000) STORE IN (dbs1, dbs2, dbs3) PARTITION p1 VALUES < 4000 IN dbs1, PARTITION p2 VALUES < 6000 IN dbs2, PARTITION p3 VALUES < 8000 IN dbs3;
If the above table has interval fragments (added automatically when emp_id values 8000 or greater were inserted), then modifying the transition value to 8500 will not be allowed.
The following statement generates an error:
ALTER FRAGMENT ON TABLE employee MODIFY INTERVAL TRANSITION TO 8500;
The difference between the new transition value, 8500, and the old transition value, 8000, is not a multiple of the interval value, 3000.
Similarly, dropping or detaching the transition fragment or the last range fragment changes the transition value. The gap created by the drop or detach must be a multiple of the interval value.
The following statement generates an error:
ALTER FRAGMENT ON TABLE employee DROP PARTITION p3;
The difference between the new transition value, 6000, and the old transition value, 8000, or the gap created by the drop is not a multiple of the interval value, 3000.
Oninit® Troubleshooting Guidance
Reasons / Common Causes
-25812 fires when ALTER FRAGMENT changes an interval-fragmented table/index's transition
value by an amount that isn't a multiple of the interval value — per the official guidance.
- A new transition value whose difference from the old one isn't a multiple of the interval value, per the official guidance — the direct, only cause.
Solutions / Resolution
- Choose a new transition value whose difference from the old one is an exact multiple of the interval value, per the official guidance.
Examples
N/A
No specific triggering statement is documented beyond a non-multiple transition-value change.
Diagnostic Checks
- Compute the difference between the old and new transition values, and confirm it's a whole multiple of the interval value.
Related Errors / Related Topics
- -25811 — "The transition value for interval fragments must be aligned to the
boundary of the interval value type." A related transition-value error, on the initial
definition's type-boundary alignment rather than an
ALTER FRAGMENTchange.
An ALTER FRAGMENT transition-value change wasn't a multiple of the interval value —
choose a value that is.