-
Notifications
You must be signed in to change notification settings - Fork 3.3k
refactor(fivetran): update handling of database and schema names to use quoted identifiers #15321
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
Open
askumar27
wants to merge
4
commits into
master
Choose a base branch
from
refactor/fivetran-database-case-sensitivity
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
+566
−53
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
…se quoted identifiers for Snowflake compatibility
❌ 1 Tests Failed:
View the top 1 failed test(s) by shortest run time
To view more test analytics, go to the Test Analytics Dashboard |
sgomezvillamor
approved these changes
Nov 18, 2025
…ntifiers in Snowflake - Added logic to handle unquoted database and schema names by converting them to uppercase quoted identifiers. - Introduced a validation method for unquoted identifiers to ensure compliance with Snowflake's requirements. - Updated tests to cover various cases for database and schema names, ensuring correct handling and transpilation for Snowflake, BigQuery, and Databricks.
…sensitivity in Snowflake - Removed outdated information regarding unquoted identifiers and emphasized the importance of using quoted identifiers for database and schema names. - Added details on backward compatibility for valid unquoted identifiers and recommended best practices for configuration. - Clarified action required for users to ensure case sensitivity in their Fivetran source configurations.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
docs
Issues and Improvements to docs
ingestion
PR or Issue related to the ingestion of metadata
pending-submitter-merge
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
📋 Summary
Quote database identifiers in Fivetran connector to align with Snowflake connector pattern and ensure consistent case-sensitive handling across all identifiers. Includes backward compatibility for valid unquoted identifiers to support existing Snowflake databases and schemas.
🎯 Motivation
This change addresses a regression identified in the postmortem where database names were not quoted while schema names were already quoted (since v1.2.0.7). The inconsistency created confusion and potential issues for users with case-sensitive or special-character database names. Also, introduced backward incompatibility with unquoted identifier usage in Snowflake configurations.
Root Cause:
Why This Matters:
Related Context:
🏗️ Architecture/Design Notes
Identifier Handling Pattern:
"→""to handle database/schema names containing quotesBackward Compatibility Strategy:
_is_valid_unquoted_identifier():Alignment with Snowflake Connector:
src/datahub/ingestion/source/snowflake/snowflake_query.pyuse database "{db_name}"and"{schema_name}".table_name📊 Impact Assessment
Breaking Changes:
Migration Impact:
No Action Required for standard identifiers (letters, numbers, underscores only):
fivetran_logs→ automatically becomesFIVETRAN_LOGS→"FIVETRAN_LOGS"Recommended Best Practice: Maintain exact case in configuration for consistency:
MYDATABASEin Snowflake → useMYDATABASEin configmydatabasein Snowflake → usemydatabasein configTimeline: Change impacts all CLI versions since v1.2.0.7 (schema quoting) and now extends to database names
Risk Level: Low
🔗 References