Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Suppress errors when SQL functions have SAFE. prefix #1

Merged
merged 4 commits into from
Apr 19, 2023

Conversation

colincadams
Copy link
Collaborator

@colincadams colincadams commented Apr 19, 2023

zetasql tells us when a function had the SAFE. prefix, by setting the error mode on the function call node to SafeMode.

This makes a change to check the error mode, and for "normal" functions, calls a separate version that suppresses any errors. For other (aggregations or analytical) functions, it throws an error that safe mode is not supported.

See goccy/bigquery-emulator#149 for the issue this addresses in the upstream repo.

This helps unblock Recidiviz/recidiviz-data#15020

@colincadams colincadams merged commit 8942dc5 into main Apr 19, 2023
@colincadams colincadams deleted the colincadams/safe_mode branch April 19, 2023 23:58
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