mirror of
https://github.com/tursodatabase/limbo.git
synced 2025-08-04 18:18:03 +00:00
fix: default values not being converted to SQL
This commit is contained in:
parent
6945c0c09e
commit
326a8b39db
2 changed files with 8 additions and 5 deletions
|
@ -249,6 +249,10 @@ impl BTreeTable {
|
|||
sql.push_str(column.name.as_ref().expect("column name is None"));
|
||||
sql.push(' ');
|
||||
sql.push_str(&column.ty.to_string());
|
||||
if let Some(default) = &column.default {
|
||||
sql.push_str(" DEFAULT ");
|
||||
sql.push_str(&default.to_string());
|
||||
}
|
||||
}
|
||||
sql.push_str(");\n");
|
||||
sql
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue