EXTFNAPIV4_DESCRIBE_COL_DISTINCT_VALUES (Set)

The EXTFNAPIV4_DESCRIBE_COL_DISTINCT_VALUES attribute describes the distinct values for a column. Used in a describe_column_set scenario.

Data Type

a_v4_extfn_estimate

Description

The estimated number of distinct values for a column. This property is valid only for table arguments.

Usage

The UDF can set this property if it knows how many distinct values a column can have in its result table. The server uses this information during the Optimization state.

Returns

On success, returns the sizeof(a_v4_extfn_estimate), if it sets the value, or:

  • EXTFNAPIV4_DESCRIBE_NOT_AVAILABLE – returned if the attribute was unavailable to set. This can happen if the column was not involved in the query.
On failure, returns:
  • EXTFNAPIV4_DESCRIBE_BUFFER_SIZE_MISMATCH – set error returned if the describe buffer is not the size of a_v4_extfn_estimate.
  • EXTFNAPIV4_DESCRIBE_INVALID_STATE – set error returned if the state is not equal to Optimization.

Query Processing States

Valid in:

Related concepts
Query Processing States
Related reference
EXTFNAPIV4_DESCRIBE_COL_DISTINCT_VALUES (Get)
Generic describe_column Errors