Updating Statistics for Columns of User-Defined Types

To calculate statistics for a column of a user-defined data type (UDT), you must use either the UPDATE STATISTICS MEDIUM FOR TABLE or the UPDATE STATISTICS HIGH FOR TABLE statement.

Without the MEDIUM or HIGH keyword, the UPDATE STATISTICS FOR TABLE statement ignores UDT columns.

Restrictions on UDT statistics

The UPDATE STATISTICS statement does not collect values for the colmin and colmax columns of the syscolumns system catalog table for columns that hold user-defined data types.

To drop distribution statistics for columns that store values of user-defined data types, you must execute UPDATE STATISTICS in LOW mode and include the DROP DISTRIBUTIONS keywords.

When you run the UPDATE STATISTICS LOW FOR TABLE DROP DISTRIBUTIONS statement, the database server deletes the row in the sysdistrib system catalog table that corresponds to the tableid and colno values for the column. In addition, the database server removes any large objects that might have been created to store distribution statistics for the specified opaque column.