SyncJounral: add an index on the error blacklist table

https://github.com/owncloud/enterprise/issues/1035
This commit is contained in:
Olivier Goffart 2016-02-11 14:38:38 +01:00
parent 893e22691d
commit cd83772112

View file

@ -613,6 +613,13 @@ bool SyncJournalDb::updateErrorBlacklistTableStructure()
commitInternal("update database structure: add lastTryTime, ignoreDuration cols");
}
SqlQuery query(_db);
query.prepare("CREATE INDEX IF NOT EXISTS blacklist_index ON blacklist(path collate nocase);");
if( !query.exec()) {
sqlFail("updateErrorBlacklistTableStructure: create index blacklit", query);
re = false;
}
return re;
}