mirror of
https://github.com/aljazceru/turso.git
synced 2026-02-11 11:14:21 +01:00
Index: add new field ephemeral: bool
This commit is contained in:
@@ -692,6 +692,7 @@ pub struct Index {
|
||||
pub root_page: usize,
|
||||
pub columns: Vec<IndexColumn>,
|
||||
pub unique: bool,
|
||||
pub ephemeral: bool,
|
||||
}
|
||||
|
||||
#[allow(dead_code)]
|
||||
@@ -741,6 +742,7 @@ impl Index {
|
||||
root_page,
|
||||
columns: index_columns,
|
||||
unique,
|
||||
ephemeral: false,
|
||||
})
|
||||
}
|
||||
_ => todo!("Expected create index statement"),
|
||||
@@ -783,6 +785,7 @@ impl Index {
|
||||
root_page,
|
||||
columns: index_columns,
|
||||
unique: true, // Primary key indexes are always unique
|
||||
ephemeral: false,
|
||||
})
|
||||
}
|
||||
|
||||
|
||||
@@ -62,6 +62,7 @@ pub fn translate_create_index(
|
||||
})
|
||||
.collect(),
|
||||
unique: unique_if_not_exists.0,
|
||||
ephemeral: false,
|
||||
});
|
||||
|
||||
// Allocate the necessary cursors:
|
||||
|
||||
Reference in New Issue
Block a user