We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Failing on constraints referring to an enum's value.
Go to this repo, and cargo test
cargo test
#[cfg(test)] mod tests { use duckdb::{params, Connection}; #[test] fn incorrect_behaviour() { let conn = Connection::open_in_memory().unwrap(); conn.execute_batch( " CREATE TYPE MyEnum AS ENUM ('A'); CREATE TABLE purchases ( currency MyEnum NOT NULL, CHECK ( currency = 'A' ) ); ", ) .unwrap(); conn.execute( " INSERT INTO purchases (currency) VALUES ('A'::MyEnum) ", params![], ) .unwrap(); } #[test] fn correct_behaviour() { let conn = Connection::open_in_memory().unwrap(); conn.execute_batch( " CREATE TYPE MyEnum AS ENUM ('A'); CREATE TABLE purchases ( currency MyEnum NOT NULL, ); ", ) .unwrap(); conn.execute( " INSERT INTO purchases (currency) VALUES ('A'::MyEnum) ", params![], ) .unwrap(); } }
Incorrect causes:
duckdb_allocator_size_0_assert-55c63b607dff2947: duckdb/src/common/allocator.cpp:122: duckdb::data_t* duckdb::Allocator::AllocateData(duckdb::idx_t): Assertion `size > 0' failed.
The text was updated successfully, but these errors were encountered:
Might be already fixed by duckdb/duckdb#12370 ?
Sorry, something went wrong.
No branches or pull requests
Issue
Failing on constraints referring to an enum's value.
Reproduce
Go to this repo, and
cargo test
Incorrect causes:
The text was updated successfully, but these errors were encountered: