Search Plex DB file for album in library other than Music

Does anyone know the correct Plex sql commands, or can point me to them, to search for an Album entry in a library other than the music library? Trying to run down why several audiobook folders have gone missing even after doing the Plex Dance with the audiobook author. I suspect there are borked entries in the DB file which causes the album to not be scanned and entered properly.

If they didn’t scan then they won’t be in the database, but here are the commands.

Select * from metadata_items where metadata_type = 9 and library_section_id = 99;

Change the 99 to the ID for your library. This will list all “albums” in that library. If you want to search for a specific word in the title

SELECT * from metadata_items WHERE metadata_type = 9 AND library_section_id = 99 AND title LIKE ‘%search%’;

replace search with the term you want to use.

Thanks for the search code. Doesn’t find the missing album. Currently digging through the database (offline copy) using DB Browser for SQLite. So far, found the missing album listed twice in the Directories table for some reason. Sill continuing to search through the tables to see if it pops up anywhere else in the DB. So far Plex won’t find the album even after the Plex Dance though the album file is properly tagged like other albums by the artist which are properly listed by Plex. Shrugs.

If you send me your logs after the dance and let me know what the album is, I can check what happened.

Thanks for the offer, however not sure its going to be needed. Ended up deleting the library entry in Plex. Then created the library again. During the initial scan which takes a considerable time due to the number of albums (over 1,000) it found the one missing audiobook album I was investigating, in addition to finding several others that were being missed apparently.

So in my case it appears the solution was to delete the library entry in Plex, create a new one where the initial scan found the missing/additional files it wasn’t finding previously.

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