# \[HowTo\] Plex database modification - Moving media the right/wrong way

**URL:** <https://forums.plex.tv/t/howto-plex-database-modification-moving-media-the-right-wrong-way/126701>\
**Category:** Tips, Tricks & How-Tos\
**Tags:** tipstricks\
**Created:** [December 9, 2015, 5:56pm UTC](https://forums.plex.tv/t/howto-plex-database-modification-moving-media-the-right-wrong-way/126701 "2015-12-09T17:56:26Z")\
**Posts on this page:** 1\
**Showing post:** 95

<div class="post-metadata">

**Author:** ![yakboyslim](https://avatars.discourse-cdn.com/v4/letter/y/85e7bf/32.png) [@yakboyslim](https://forums.plex.tv/u/yakboyslim)\
**Post date:** [October 26, 2021, 3:54pm UTC](https://forums.plex.tv/t/howto-plex-database-modification-moving-media-the-right-wrong-way/126701/95 "2021-10-26T15:54:19Z")

</div>

For those looking to do this using DB Browser (thanks to @yooniverse ):

In DB Browser, delete the two triggers, and write (commit) the change:  
fts4\_metadata\_titles\_before\_update\_icu  
fts4\_metadata\_titles\_after\_update\_icu

Run your metadata update SQL statements.

Then recreate the two triggers, then commit:

CREATE TRIGGER fts4\_metadata\_titles\_before\_update\_icu BEFORE UPDATE ON metadata\_items BEGIN DELETE FROM fts4\_metadata\_titles\_icu WHERE docid=old.rowid; END;

CREATE TRIGGER fts4\_metadata\_titles\_after\_update\_icu AFTER UPDATE ON metadata\_items BEGIN INSERT INTO fts4\_metadata\_titles\_icu(docid, title, title\_sort, original\_title) VALUES(new.rowid, new.title, new.title\_sort, new.original\_title); END

> [@Can no longer update library database with sqlite3](https://forums.plex.tv/t/can-no-longer-update-library-database-with-sqlite3/701405/43):
>
> In DB Browser, delete the two triggers, and write (commit) the change: fts4\_metadata\_titles\_before\_update\_icu fts4\_metadata\_titles\_after\_update\_icu Run your metadata update SQL statements. For example, to chronologically reorder: UPDATE metadata\_items SET added\_at = originally\_available\_at WHERE library\_section\_id = 25; Then recreate the two triggers, then commit: CREATE TRIGGER fts4\_metadata\_titles\_before\_update\_icu BEFORE UPDATE ON metadata\_items BEGIN DELETE FROM fts4\_metadata\_titles…

---

_[View the full topic](https://forums.plex.tv/t/howto-plex-database-modification-moving-media-the-right-wrong-way/126701)._
