The AM_TRUNCATE Purpose Function
HCL OneDB™ provides built-in am_truncate purpose functions for its primary access methods that support TRUNCATE operations on columns of permanent and temporary tables. It also provides a built-in am_truncate purpose function for its secondary access method for TRUNCATE operations on B-tree indexes.
CREATE PRIMARY ACCESS_METHOD vti( AM_GETNEXT = vti_getnext AM_TRUNCATE = vti_truncate ...);
ALTER ACCESS_METHOD abc (ADD AM_TRUNCATE = abc_truncate);
In these examples, the vti_truncate and abc_truncate functions must be routines that support the functionality of the AM_TRUNCATE purpose option keyword, and that were previously registered in the database by the CREATE FUNCTION or CREATE ROUTINE FROM statement.