snowflake.snowpark.functions.is_binary¶
- snowflake.snowpark.functions.is_binary(col: Union[Column, str]) Column [source] (https://github.com/snowflakedb/snowpark-python/blob/v1.16.0/src/snowflake/snowpark/functions.py#L4522-L4534)¶
Returns true if the specified VARIANT column contains a binary value.
Examples:
>>> from snowflake.snowpark.types import StructField, VariantType >>> df = session.create_dataframe([[b"snow", "snow"]], schema=["a", "b"]) >>> df.select(is_binary(to_variant(df["a"])).alias("binary"), is_binary(to_variant(df["b"])).alias("varchar")).collect() [Row(BINARY=True, VARCHAR=False)]