Skip to content

Conversation

fivetran-amrutabhimsenayachit
Copy link
Collaborator

@fivetran-amrutabhimsenayachit
Copy link
Collaborator Author

HEX_DECODE_BINARY is already handled and has a func class - UnHex.

**Cross-Dialect Transpilation:**
Snowflake: HEX_DECODE_BINARY("48656C6C6F")
BigQuery: FROM_HEX(\48656C6C6F\)
DuckDB: UNHEX("48656C6C6F")
PostgreSQL: UNHEX("48656C6C6F")

Following tests already exist:

self.validate_all(
            "SELECT HEX_DECODE_BINARY('65')",
            write={
                "bigquery": "SELECT FROM_HEX('65')",
                "duckdb": "SELECT UNHEX('65')",
                "snowflake": "SELECT HEX_DECODE_BINARY('65')",
            },
        )

@georgesittas georgesittas merged commit f8c0ee4 into main Sep 20, 2025
6 checks passed
@georgesittas georgesittas deleted the RD-1036060-add-functions-and-annotate-for-snowflake-hex-functions branch September 20, 2025 09:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants