Open
Description
I'm finding that Sqlite migrations that use the defaultTo_
function don't work. I think it's because they try to use a wildcard to insert the default value.
I made a full repro here: https://github.com/thomasjm/beam-sqlite-default-repro
Here's what happens when you run it (formatted slightly for readability):
CREATE TABLE "repro"("id" INTEGER PRIMARY KEY AUTOINCREMENT,
"ref_count" INTEGER DEFAULT (?) NOT NULL );
-- With values: [SQLInteger 0]
beam-sqlite-default-repro-exe: SQLite3 returned ErrorError while attempting to perform prepare
"CREATE TABLE \"repro\"(\"id\" INTEGER PRIMARY KEY AUTOINCREMENT,
\"ref_count\" INTEGER DEFAULT (?) NOT NULL )":
default value of column [ref_count] is not constant