Help with editing Plex Database in SQL

Server Version#: 1.14.1.5488
Player Version#:

I’d like to change the location of my media files with the minimum amount of work since I have a large database and so don’t want to have to reload all the media.

I have been reading this forum post on using SQL:

which shows how to edit the section_locations table

As a test run I tried changing all the paths on a small test database from D:\Media\Movies to D:\Video\Movies

The SQL edit worked but it only changed the entries in the

Library > Edit > Add Folders

When I looked at the info for an individual movie it still contained the old path to D:\Media\Movies and so Plex reported a media unavailable error when I tried to play the movie.

Is it possible in SQL to change the path for every Movie please?

So then…

If I then used the ‘Scan Library Files’ option in Plex it corrected all the entries with the new location and so Plex then plays everything OK.

So that solves the problem, but might that take a long time with a large database? Would it be quicker than deleting and reloading all the media from scratch which is what I would like to avoid?

Your advice and tips are appreciated :slight_smile:

You might want to have a look at this thread which discusses what needs to be changed and how to change it… While you are there make sure you check out the last dozen or so posts as it has a way to get you files moved without database editing… Good luck!!!

Not exactly sure why you’re so desperate to do this by editing the database itself.
Just have a read at this support article… worked great for me when I re-organized my mounted drives on Ubuntu 18.04.
https://support.plex.tv/articles/201154537-move-media-content-to-a-new-location/

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.