mirror of
https://github.com/aljazceru/turso.git
synced 2026-01-03 08:24:19 +01:00
implement pragma table_info
Both () and = variants covered. It is important to make sure that the transaction is a read transaction, so we cannot hide all that logic inside update_pragma, and have to make our decision before that.
This commit is contained in:
@@ -1593,6 +1593,8 @@ pub enum PragmaName {
|
||||
JournalMode,
|
||||
/// trigger a checkpoint to run on database(s) if WAL is enabled
|
||||
WalCheckpoint,
|
||||
/// returns information about the columns of a table
|
||||
TableInfo,
|
||||
}
|
||||
|
||||
impl FromStr for PragmaName {
|
||||
@@ -1603,6 +1605,7 @@ impl FromStr for PragmaName {
|
||||
"cache_size" => Ok(PragmaName::CacheSize),
|
||||
"wal_checkpoint" => Ok(PragmaName::WalCheckpoint),
|
||||
"journal_mode" => Ok(PragmaName::JournalMode),
|
||||
"table_info" => Ok(PragmaName::TableInfo),
|
||||
_ => Err(()),
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user