Type Casts

A type cast specifies a conversion from one data type to another

Explicit Cast

The semantics of CAST are the same as the semantics of the corresponding TO_ datatype conversion functions. The :: operator provides the alternative syntax for CAST.

This syntax is fully supported by Snowflake.

Sample Source Patterns

SQL Input Code

SELECT col1::integer FROM tbl;

Snowflake Output Code

SELECT col1::integer FROM tbl;

Last updated