Informix Error -9882: Access method AM_SPTYPE purpose value <space-types> is invalid. </space-types>
Cause and resolution
Access method AM_SPTYPE purpose value <space-types> is invalid. </space-types>
The operation failed because the access method specified in the SQL statement has an invalid value, <space-types>, for its AM_SPTYPE purpose value. </space-types>
Because processing for the CREATE PRIMARY ACCESS_METHOD and CREATE SECONDARY ACCESS_METHOD SQL statements validates the AM_SPTYPE value, this error should only occur if the row associated with the access method in the sysams system catalog table was explicitly updated after the access method was created.
Ask the access-method provider or database administrator to change the AM_SPTYPE value for the access method with the ALTER ACCESS_METHOD statement.
Oninit® Troubleshooting Guidance
Reasons / Common Causes
-9882 fires when an access method's AM_SPTYPE purpose value, as stored in the sysams
system catalog table, is invalid — per the official guidance.
- The
sysamsrow for the access method having been explicitly updated after creation, per the official guidance — the direct, only cause; CREATE PRIMARY/SECONDARY ACCESS_METHOD validates AM_SPTYPE at creation time, so this normally indicates the catalog row was altered afterward.
Solutions / Resolution
- Ask the access-method provider or database administrator to correct AM_SPTYPE using ALTER ACCESS_METHOD, per the official guidance.
Examples
Correcting AM_SPTYPE
ALTER ACCESS_METHOD my_am (am_sptype = 'X');
Diagnostic Checks
- Check the access method's
sysamsrow for its current AM_SPTYPE value, and correct it with ALTER ACCESS_METHOD.
Related Errors / Related Topics
- -9855 — "Improper value used for purpose purpose_name for access method." A related purpose-value validity error, general to CREATE/ALTER ACCESS_METHOD rather than a post-creation catalog inconsistency specific to AM_SPTYPE.
The access method's AM_SPTYPE catalog value was invalid, likely from a direct catalog edit — correct it with ALTER ACCESS_METHOD.