fix(c/driver/sqlite): accept unprefixed named parameters - #4773
Open
emecii wants to merge 2 commits into
Open
Conversation
Preserve exact named bindings and reject ambiguous prefix-free matches. Add native and Python regression coverage and document the matching rules. Generated-by: OpenAI Codex
There was a problem hiding this comment.
🟡 Changes recommended
Alias and exact input names can resolve to one index while another SQL parameter remains silently unbound.
Once you've addressed the issues Copilot identified, you can request another Copilot review.
Pull request overview
Enables SQLite named binding without :, @, or $ prefixes when uniquely matched.
Changes:
- Adds unique unprefixed-name resolution and ambiguity errors.
- Adds native and Python regression coverage.
- Documents matching and precedence rules.
File summaries
| File | Description |
|---|---|
c/driver/sqlite/statement_reader.c |
Implements unprefixed matching. |
c/driver/sqlite/sqlite_test.cc |
Adds native binding tests. |
python/adbc_driver_sqlite/tests/test_dbapi.py |
Adds DB-API regressions. |
docs/source/driver/sqlite.rst |
Documents named parameters. |
Review details
- Files reviewed: 4/4 changed files
- Comments generated: 1
- Review effort level: Balanced
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
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
Accept unprefixed names for SQLite's
:,@, and$named parameters when the match is unique. Exact prefixed names keep their existing behavior; ambiguous unprefixed names produce an explicit error. Positional binding and parameter-count validation are unchanged.AI disclosure: OpenAI Codex generated this implementation, tests, and PR description; automated validation is listed above.
Closes #3520