-
Notifications
You must be signed in to change notification settings - Fork 2.5k
Closed
Labels
Description
What happens?
The C API function duckdb_param_type
, when called for a parameter of type VARCHAR, returns DUCKDB_TYPE_INVALID.
To Reproduce
Here's a test case that fails:
TEST_CASE("Test duckdb_param_type for VARCHAR", "[capi]") {
duckdb_database db;
duckdb_connection conn;
duckdb_prepared_statement stmt;
REQUIRE(duckdb_open("", &db) == DuckDBSuccess);
REQUIRE(duckdb_connect(db, &conn) == DuckDBSuccess);
REQUIRE(duckdb_prepare(conn, "select ?", &stmt) == DuckDBSuccess);
REQUIRE(duckdb_bind_varchar(stmt, 1, "a") == DuckDBSuccess);
REQUIRE(duckdb_param_type(stmt, 1) == DUCKDB_TYPE_VARCHAR);
}
It fails on the final REQUIRE with 0 == 17
.
OS:
Mac OS X
DuckDB Version:
main branch
DuckDB Client:
C API
Hardware:
Apple M2 Max
Full Name:
Jeff Raymakers
Affiliation:
MotherDuck
What is the latest build you tested with? If possible, we recommend testing with the latest nightly build.
I have tested with a source build
Did you include all relevant data sets for reproducing the issue?
Yes
Did you include all code required to reproduce the issue?
- Yes, I have
Did you include all relevant configuration (e.g., CPU architecture, Python version, Linux distribution) to reproduce the issue?
- Yes, I have