Skip to content

SNOW-3083544: Support PERMISSIVE mode for TRY_CAST#4078

Draft
sfc-gh-joshi wants to merge 2 commits intomainfrom
joshi/try-cast-permissive
Draft

SNOW-3083544: Support PERMISSIVE mode for TRY_CAST#4078
sfc-gh-joshi wants to merge 2 commits intomainfrom
joshi/try-cast-permissive

Conversation

@sfc-gh-joshi
Copy link
Contributor

  1. Which Jira issue is this PR addressing? Make sure that there is an accompanying issue to your PR.

    Fixes SNOW-3083544

  2. Fill out the following pre-review checklist:

    • I am adding a new automated test(s) to verify correctness of my new code
      • If this test skips Local Testing mode, I'm requesting review from @snowflakedb/local-testing
    • I am adding new logging messages
    • I am adding a new telemetry message
    • I am adding new credentials
    • I am adding a new dependency
    • If this is a new feature/behavior, I'm adding the Local Testing parity changes.
    • I acknowledge that I have ensured my changes to be thread-safe. Follow the link for more information: Thread-safe Developer Guidelines
    • If adding any arguments to public Snowpark APIs or creating new public Snowpark APIs, I acknowledge that I have ensured my changes include AST support. Follow the link for more information: AST Support Guidelines
  3. Please describe how your code solves the related issue.

Adds support for a new PERMISSIVE mode in TRY_CAST, which nulls individual mismatched fields instead of erroring out (SNOW-2146233). The server-side work for this is still in-progress, so this PR will remain in draft mode until it is merged.

AST generation appears to not support the existing RENAME FIELDS/ADD FIELDS arguments for CAST either, so I left AST untouched for the time being.

Copy link
Contributor

@sfc-gh-fhe sfc-gh-fhe left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. I think we can add an error test to be sure

@sfc-gh-joshi sfc-gh-joshi force-pushed the joshi/try-cast-permissive branch from 07842a1 to c6b8baf Compare February 24, 2026 23:54
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.

2 participants