AS_TIMESTAMP_NTZ
functionsupportedCore SQL functionsCasts a VARIANT value to the respective timestamp value: - AS_TIMESTAMP_LTZ (value with local time zone) - AS_TIMESTAMP_NTZ (value with no time zone) - AS_TIMESTAMP_TZ (value with time zone)
Syntax
AS_TIMESTAMP_LTZ( <variant_expr> )
AS_TIMESTAMP_NTZ( <variant_expr> )
AS_TIMESTAMP_TZ( <variant_expr> )
Parameters
| Name | Required | Description |
|---|---|---|
variant_expr | required | An expression that evaluates to a value of type VARIANT. |
Returns
The function returns a value of a timestamp type or NULL: - If the type of the value in the variant_expr argument is a timestamp type, the function returns a value of same timestamp type. - If the type of the value in the variant_expr argument doesn’t match the type of the output value, the function returns NULL. - If the variant_expr argument is NULL, the function returns NULL.