Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add indexes to improve backup query performance.
- Loading branch information
Showing
3 changed files
with
24 additions
and
2 deletions.
There are no files selected for viewing
12 changes: 12 additions & 0 deletions
12
Duplicati/Library/Main/Database/Database schema/12. Performance Indexes.sql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
CREATE INDEX "nnc_Metadataset" ON Metadataset ("ID","BlocksetID") | ||
CREATE INDEX "nn_FilesetentryFile" on FilesetEntry ("FilesetID","FileID") | ||
|
||
-- Line 602 & 603 LocalBackupDatabase.cs | ||
-- CREATE INDEX "tmpName1" ON "{0}" ("Path"),tmpName1 | ||
-- CREATE INDEX "tmpName2" ON "{0}" ("Path"),tmpName2 | ||
|
||
CREATE INDEX "nn_FileLookup_BlockMeta" ON FileLookup ("BlocksetID", "MetadataID") | ||
|
||
CREATE INDEX "nnc_BlocksetEntry" ON "BlocksetEntry" ("Index", "BlocksetID", "BlockID") | ||
|
||
UPDATE "Version" SET "Version" = 12; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
396119a
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This commit has been mentioned on Duplicati. There might be relevant details there:
https://forum.duplicati.com/t/the-database-has-version-12-but-the-largest-supported-version-is-11/15554/2