Skip to content

featurebyte.UserDefinedFunction.update_output_dtype

update_output_dtype(
output_dtype: Literal["BINARY", "BOOL", "CHAR", "DATE", "FLOAT", "INT", "TIME", "TIMESTAMP", "TIMESTAMP_TZ", "VARCHAR", "OBJECT", "TIMEDELTA", "VOID", "ARRAY", "MAP", "STRUCT", "UNKNOWN"]
)

Description

Update the output data type of the user-defined function.

Parameters

  • output_dtype: Literal["BINARY", "BOOL", "CHAR", "DATE", "FLOAT", "INT", "TIME", "TIMESTAMP", "TIMESTAMP_TZ", "VARCHAR", "OBJECT", "TIMEDELTA", "VOID", "ARRAY", "MAP", "STRUCT", "UNKNOWN"]
    The output data type of the user-defined function.

Examples

>>> cos_udf = catalog.get_user_defined_function("cos")
>>> cos_udf.update_output_dtype(DBVarType.INT)
>>> cos_udf.output_dtype
'INT'