snowflake.snowpark.functions.to_time¶
- snowflake.snowpark.functions.to_time(e: Union[Column, str], fmt: Optional[Union[Column, str]] = None) Column [source] (https://github.com/snowflakedb/snowpark-python/blob/v1.16.0/src/snowflake/snowpark/functions.py#L3114-L3124)¶
Converts an input expression into the corresponding time.
Example:
>>> df = session.create_dataframe(['04:15:29.999'], schema=['a']) >>> df.select(to_time(col("a"))).collect() [Row(TO_TIME("A")=datetime.time(4, 15, 29, 999000))]