Build your personal knowledge base with Trilium Notes
TypeScript electronelectron-appknowledge-baseknowledge-graphknowledge-managementknowledge-management-graphlocal-firstnote-managmentnote-takernote-takingnotebooknotesnotes-apppersonal-knowledge-basepersonal-wikiscriptableself-hostedself-hostingwiki
fix migration script
zadambc9903191e7c
diff --git a/db/migrations/0188__set_hidden_branchId.sql b/db/migrations/0188__set_hidden_branchId.sqlindex abb2d18f5e..8ef8116d70 100644--- a/db/migrations/0188__set_hidden_branchId.sql+++ b/db/migrations/0188__set_hidden_branchId.sql@@ -1 +1,8 @@-UPDATE branches SET branchId = 'hidden' where parentNoteId = 'root' AND noteId = 'hidden';+UPDATE branches SET branchId = 'hidden' where branchId = (+ SELECT branchId FROM branches+ WHERE parentNoteId = 'root'+ AND noteId = 'hidden'+ AND isDeleted = 0+ ORDER BY utcDateModified+ LIMIT 1+);