Informix Error -25813: The partition name used in the fragmentation scheme is not allowed.
Cause and resolution
The partition name used in the fragmentation scheme is not allowed.
The system-generated partition names for interval fragments start with 'sys_p'. Therefore, the partition names for initial fragments of an interval fragmented table or index cannot have names that start with the same characters.
The following statement generates an error:
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(hire_date) INTERVAL(3 UNITS YEAR) STORE IN (dbs1, dbs2, dbs3) PARTITION sys_p1 VALUES < DATE('01/01/2006') IN dbs3;
In the above example the partition name starts with 'sys_p', which is not allowed, because the 'sys_p' prefix is reserved for system-defined storage objects.
The correct usage is as follows:
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(hire_date) INTERVAL(3 UNITS YEAR) STORE IN (dbs1, dbs2, dbs3) PARTITION pt1 VALUES < DATE('01/01/2006') IN dbs3;
Oninit® Troubleshooting Guidance
Reasons / Common Causes
-25813 fires when an initial interval fragment's partition name starts with sys_p — per
the official guidance, this prefix is reserved for system-generated interval-fragment
partition names.
- A user-supplied partition name starting with
sys_p, per the official guidance — the direct, only cause.
Solutions / Resolution
- Rename the partition to avoid the
sys_pprefix, per the official guidance.
Examples
A reserved partition name
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(hire_date) INTERVAL(3 UNITS YEAR) STORE IN (dbs1, dbs2, dbs3)
PARTITION sys_p1 VALUES < DATE('01/01/2006') IN dbs3;
-- -25813: sys_p1 starts with the reserved sys_p prefix
Diagnostic Checks
- Check every partition name for the
sys_pprefix, and rename any that use it.
Related Errors / Related Topics
- -25802 — "The PARTITION clause is mandatory for interval and list fragmentation." A
related
PARTITION-clause error, on a missing clause rather than a reserved name.
An initial interval-fragment partition name used the reserved sys_p prefix — rename it.