fix(snowflake): escape SQL identifiers and literals in metadata/DDL paths (#1914) - #2200
Merged
Merged
Conversation
…per maintainer review (OtterMind#1914) - new SnowflakeIdentifierProcessor (SPI ISQLIdentifierProcessor): quoteIdentifier with double-quote doubling, escapeString with single-quote doubling - SnowflakeMetaData overrides getSQLIdentifierProcessor(); metadata call sites use it - builder/enums/DBManager use SnowflakeIdentifierProcessor.INSTANCE - non-escapable validation moved to SnowflakeSqlGuards (name tokens, default expressions, index sort direction); USE SCHEMA keeps unquoted+whitelist schema - SnowflakeSqlEscapes removed; tests migrated (19 green)
…quote for DDL paths (OtterMind#1914)
Preserve identifier round trips and Snowflake case folding, quote inherited DML builder paths, and validate raw defaults, custom types, index metadata, and clustering clauses. Co-authored-by: HandSonic <8078023+handsonic@users.noreply.github.com>
openai0229
force-pushed
the
fix/sqli2-snowflake
branch
from
July 29, 2026 11:32
6f6ba1f to
11b4f5f
Compare
openai0229
approved these changes
Jul 29, 2026
openai0229
left a comment
Contributor
There was a problem hiding this comment.
Rebased on the latest main and verified the complete Snowflake identifier/literal handling path. The clean 9-module reactor passes, including Snowflake 28/28, MySQL 653/653, SPI 90/90, and tools 26/26.
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Related issue
Closes #1914
Summary
Completes the Snowflake database-plugin portion of the identifier and literal escaping work.
Affected surfaces
Verification
mvn -pl chat2db-community-plugins/chat2db-community-snowflake -am clean test -Dmaven.test.skip=false -DskipTests=falseBUILD SUCCESSacross 9 reactor modules; 797 tests passed in tested modules, including Snowflake28/28, MySQL653/653, SPI90/90, and tools26/26.git diff --check origin/main...HEAD: passed.Risk and compatibility
ISQLIdentifierProcessorcontract.Reviewer map
SnowflakeIdentifierProcessor,SnowflakeSqlGuards, andSnowflakeIdentifierProcessorTest, then review metadata and builder call sites.Contributor declaration
AI assistance: Substantial AI-assisted maintainer revision and test expansion; all final changes were source-reviewed and verified with the commands above.