trilium/db/migrations/0105__delete_content_from_soft_deleted_notes.sql

2 lines
No EOL
167 B
SQL

UPDATE notes SET content = '' WHERE isDeleted = 1;
UPDATE note_revisions SET content = '' WHERE (SELECT isDeleted FROM notes WHERE noteId = note_revisions.noteId) = 1;