Open
Description
Checking the tests showed that some behavior changed, not only the tests. Each row below has steps you can repeat. "Seen" means we ran it against sqlx-odbc. The old driver was read, not run.
| What changed | Steps to see it | sqlx-oldapi | sqlx-odbc | Evidence |
|---|---|---|---|---|
2A :: u64 above i64::MAX cannot be read |
Run SELECT CAST(18446744073709551615 AS DECIMAL(20, 0)), then try_get::<u64, _>(0) |
Returns u64::MAX (read from source) |
Fails: "source value is not an integer" (seen on PostgreSQL and DuckDB) | new, old Proposed fix in #29. |
2B :: Any always reports an empty statement cache |
Bind one value in a query on an AnyConnection, then call cached_statements_size() |
1 | 0 (seen). OdbcConnection reports 1 |
any.rs Proposed fix in #31. |
2C :: Any rejects whole rows with a decimal, numeric, date, time or timestamp column |
Run SELECT 3.14 on an AnyConnection |
Reads it as f64 |
Fails the whole row (seen) | any.rs |
| 2D :: Connection failures change error type | Connect with DSN=no_such_dsn |
Error::Configuration |
Error::Database (seen) |
new, old |
| 2E :: sqlx-odbc does not build with sqlx's default features | Run cargo check --features sqlx-core/offline in sqlx-odbc |
Builds | Fails with E0046, missing describe (seen) |
connection.rs Proposed fix in #30. |
2F :: bool is not compatible with BIT |
Read a BIT value with try_get::<bool, _> |
Works | Fails with "mismatched types". PostgreSQL and DuckDB send booleans as text, so only drivers that return BIT values hit this |
arguments.rs Fixed on main in 80b1f4f. |
2G :: bool is sent as a bit, not an integer |
Bind true |
Sends the integer 1 | Sends an ODBC bit | new, old |
| 2H :: A prepare with deferred column metadata is cached | Prepare a query on a driver that defers column metadata | Not cached | Cached | new, old |
Metadata
Metadata
Assignees
Labels
No labels
Activity
sqlx-oldapi#181reap commentedon Nov 13, 2026
2A
81reap commentedon Nov 13, 2026
2B
81reap commentedon Nov 13, 2026
2C
81reap commentedon Nov 13, 2026
2D
81reap commentedon Nov 13, 2026
2E
$ cargo check --features sqlx-core/offline Checking sqlx-odbc v0.0.3 (/home/reap/Desktop/sqlx-odbc) error[E0046]: not all trait items implemented, missing: `describe` --> src/any.rs:29:1 | 29 | impl AnyConnectionBackend for OdbcConnection { | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ missing `describe` in implementation | = help: implement the missing item: `fn describe(&mut self, _: SqlStr) -> Pin<Box<dyn futures_core::Future<Output = std::result::Result<sqlx_core::describe::Describe<sqlx_core::any::Any>, sqlx_core::Error>> + std::marker::Send>> { todo!() }` error[E0046]: not all trait items implemented, missing: `describe` --> src/connection.rs:385:1 | 385 | impl<'c> Executor<'c> for &'c mut OdbcConnection { | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ missing `describe` in implementation | = help: implement the missing item: `fn describe<'e>(self, _: SqlStr) -> Pin<Box<(dyn futures_core::Future<Output = std::result::Result<sqlx_core::describe::Describe<<Self as Executor<'c>>::Database>, sqlx_core::Error>> + std::marker::Send + 'e)>> { todo!() }` For more information about this error, try `rustc --explain E0046`. error: could not compile `sqlx-odbc` (lib) due to 2 previous errors81reap commentedon Nov 13, 2026
2F
81reap commentedon Nov 13, 2026
2G
81reap commentedon Nov 13, 2026
2H
[SLOP][DO NOT MERGE][@81reap to cleanup]