Repository navigation
Clarify docs on in-memory pooling, execution options and bulk insert fallbacks - #226
Conversation
Codex Review Summary: ✅ CompletedThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 2d744387e8
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
|
|
||
| - DuckDB has no SAVEPOINT, so `begin_nested()` raises. `with_for_update()` is ignored. | ||
| - DuckDB cannot add UNIQUE, FOREIGN KEY or CHECK constraints to an existing table. Alembic batch mode recreates the table. | ||
| - `result.rowcount` reports rows changed by INSERT, UPDATE, DELETE and MERGE. It is -1 with RETURNING and for `executemany`. |
There was a problem hiding this comment.
Correct the rowcount caveat for RETURNING and batch inserts
The new caveat contradicts the dialect's behavior: Core DML with RETURNING materializes the returned rows and reports their count, and Core inserts with multiple parameter sets can report the full count when handled in one insertmanyvalues page or by the registration path. For example, test_returning_preserves_rows_and_affected_count expects rowcount == matches, while test_dml_rowcount_reports_changed_rows expects a two-row Core batch to report 2. Restrict the -1 warning to the DBAPI executemany cases that actually lack a count, such as batched UPDATE/DELETE and textual INSERTs.
Useful? React with 👍 / 👎.
| - a value is a `timedelta`, a `time` with a time zone, a non-finite `Decimal`, | ||
| or a `Decimal` that needs more than 38 digits |
There was a problem hiding this comment.
Include oversized integers in the fallback checklist
For a batch containing a Python integer whose magnitude reaches 2**127—for example, when loading it into a text or variable-width numeric column—Arrow construction fails and build_bulk_insert_dataframe() explicitly rejects the value, so the batch remains on the ordinary path. The newly expanded checklist is presented as the set of fallback cases but omits this condition, leaving users diagnosing why the optimization was skipped without the documented cause.
Useful? React with 👍 / 👎.
Summary
Documentation only. No code or version change, so nothing publishes.
:memory:pooling statement.docs/configuration.mdsaid every connection sees the same in-memory database.SingletonThreadPoolopens one connection per thread and each gets its own database, so a second thread does not see the first thread's tables. The guide now says so and recommends a named:memory:namedatabase or a file when threads share data.docs/types-and-caveats.md, including the retry options andarraysize, with defaults and links.docs/performance.md, matching the checks in_bulk_insert.pyand_bulk_insert_register_columns.docs/performance.md.docs/index.mdgroups guides by task with one-line descriptions.llms.txtfollows the llms.txt format with full URLs, a description per guide, and the facts agents most often need.CLAUDE.mdandARCHITECTURE.mdrecord the thread-private:memory:behavior and the relation cache rule.Test evidence
:memory:claim was checked with a real engine: a table created in one thread is absent from a connection opened in another thread.pre-commitpasses on the changed files.pytest duckdb_sqlalchemy: 896 passed, 10 skipped.