Add PRAGMA key to set the encryption key

If set, set the key for the connection
This commit is contained in:
Avinash Sajjanshetty
2025-08-12 21:44:25 +05:30
parent 100a0d8e97
commit 93774ffc3b
4 changed files with 54 additions and 4 deletions

View File

@@ -1829,6 +1829,11 @@ pub enum PragmaName {
IntegrityCheck,
/// `journal_mode` pragma
JournalMode,
/// encryption key for encrypted databases. This is just called `key` because most
/// extensions use this name instead of `encryption_key`.
#[strum(serialize = "key")]
#[cfg_attr(feature = "serde", serde(rename = "key"))]
EncryptionKey,
/// Noop as per SQLite docs
LegacyFileFormat,
/// Set or get the maximum number of pages in the database file.