This function can only be called from within an aggregate UDF. Calling this function from an external stored procedure, scalar UDM, scalar function, or table function results in an error.
The value of interim_size in the CLASS AGGREGATE clause of the CREATE FUNCTION statement determines the maximum size of the structure. If interim_size is not specified, then the limit is 64 bytes. The absolute limit is 64000 bytes.