fix: CockroachDB adapter phase 2 — fix SQL generation and remove soft-fail#1999
Merged
fix: CockroachDB adapter phase 2 — fix SQL generation and remove soft-fail#1999
Conversation
…-fail CockroachDB was marked as soft-fail in CI because tests failed. Three root causes fixed: 1. Missing CockroachDB in adapter name checks — update.cfc and sql.cfc had hardcoded adapter lists (PostgreSQL,H2,...) that excluded CockroachDB, causing UPDATE SET clauses to generate invalid SQL. 2. Identity select not passing RETURNING result — $executeQuery now passes the cfquery result as returningIdentity to $identitySelect, fixing generated key retrieval on Adobe CF. 3. Boolean type mapping — changed cf_sql_boolean to cf_sql_bit for Adobe CF compatibility (ACF doesn't support cf_sql_boolean in cfqueryparam). Also adds CockroachDB-specific test specs (CRUD, transactions, types) and guards core tests that assume sequential IDs or PostgreSQL transaction semantics. Closes #1972, closes #1974 Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
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.
Summary
CockroachDBto adapter name checks inupdate.cfcandsql.cfcthat previously only listedPostgreSQL,H2,Oracle,SQLite— CockroachDB'sUPDATE SETclauses were generating invalid SQLreturningIdentityto$identitySelect, and add the parameter to all adapter signatures. Fixes generated key retrieval on Adobe CF + CockroachDBcf_sql_booleantocf_sql_bitin CockroachDB adapter for Adobe CF compatibilityCockroachDBCrudSpec,CockroachDBTransactionSpec,CockroachDBTypeSpecfor CockroachDB-appropriate test coverageCloses #1972, closes #1974
Test plan
🤖 Generated with Claude Code