"Recently added" section showing stuff that was NOT recently added

So for the past month or two the “recently added” section of plex has been randomly showing things that were not recently added to the server, or changed on the server in any way. This seems to only happen with the TV Show section and not with movies. This afternoon, for example, “Alfred Hitchcock Presents” is in the newest slot on recently added, and that was added to the server two years ago. I hoped that a new update would do it, but I’m on the latest PMS - 0.9.16.3 - and I’ve been through a few updates over the last 2 months and the behavior hasn’t changed.

No idea what’s going on or how to fix it. Help?

Check your filenames for special characters and .

No luck. Perfect Strangers and the Twilight Zone just randomly appeared, no special characters anywhere. This is really weird and it makes the “recently added” section pretty much useless.

If it helps, the data itself is on a Synology NAS, but the server is a Mac Mini.

Hi,
I have the same problem. It started a year ago with 3 movies. No international chars in the file names. I´ve tried the old trick of moving them out of the disk, clean bundles, empty trash and bringing them back. It helped a for a short time but after a while they kept appearing as new. I have also a Mac Mini (on Mac OSX Yosemite 10.10.5) running Plex Server (Version 0.9.16.3) and a NAS (Synology) to hold the files.

Now the problem expanded to include several music albums.

How can I stop this? I can post XMLs of the files involved or activate the detailed logging and post teh results here it this helps.

Okay, I completely uninstalled Plex Media Server, erased every configuration file I could find, and reinstalled from scratch. It was a lot of work re-matching and re-indexing and re-sorting everything just how I had it before.

It has been 3 days and so far so good. I’m going to mark this as answered so the forum software stops bugging me about it.

Well it happened again, adding season 11 of the Simpsons out of nowhere. This is very frustrating after removing Plex and every trace of Plex that I could find and then carefully re-indexing a lot of movies manually. I just don’t know what else to do. It makes the “Recently Added” section pretty much useless – and that used to be my most-used feature in Plex across all the platforms.

Damn it.

After updating to the latest version (Ubuntu) I am experiencing the same issue on the dashboard. It looks to be limited to just “Recently added television”.

I’ve previously seen the same issue in the iOS app, and then found it to be filenames with timestamps set in the future. I’ve fixed this for all the affected files (using “find” to find the files with a timestamp newer than current date). I’ve double checked, and this is not the issue this time around.

I had same issue with 2 episodes stuck in the “recently added” and won’t budge not matter what.
I was able to solve the issue using information I gathered from few other posts.

I opened the XML info of the file and found out the “addedAt” values for those 2 episodes were somewhere in 2038. As much as I have patience, but waiting 22 years is unacceptable. So I took matters into hands and started digging.

Here are the instructions to repair those items manually.

  • Find the location of your Plex server sqlite database. On linux it’s something like that: /Library/Application Support/Plex Media Server/Plug-in Support/Databases/com.plexapp.plugins.library.db )
  • Install an Sqlite management tool and open the database file with it. I used sqlite3 on linux.
  • Open the XML info of the corrupted item in Plex Web (Open “Info” for the episode and click “View XML”).
  • Locate the property “ratingKey”. This will be the id of the record in the metadata_items table.
  • Run the following command in Sqlite (replace [ratingKey] with actual value from last step):

UPDATE metadate_items
SET added_at = created_at
WHERE id=
[ratingKey]

Done!

I hope this was helpful.

3 Likes

The above information looks very helpful. But in my case it turned out to be on Synology’s end. My NAS volume was unstable and eventually crashed. After a call to tech support and lots of copying I got my data back, scanned all the drives, set the volume up again, and copied the data back over.

No problems since. Sorry Plex!

@n_shay said:
UPDATE metadate_items
SET added_at = created_at
WHERE id=
[ratingKey]
This was what I was looking for, more or less. I just wanted to suggest a simpler approach:

UPDATE metadata_items
SET added_at = created_at
WHERE DATETIME(added_at) > DATETIME('now');

This way you don’t have to go through each and every episode to get the ratingKey, simply just update all items where the added_at date is in the future.

This one-liner should do it on Ubuntu:

sudo service plexmediaserver stop && sudo sqlite3 /var/lib/plexmediaserver/Library/Application Support/Plex Media Server/Plug-in Support/Databases/com.plexapp.plugins.library.db "UPDATE metadata_items SET added_at = created_at WHERE DATETIME(added_at) > DATETIME('now');" && sudo service plexmediaserver start

Of course you need sqlite3 installed:

sudo apt-get install sqlite3
6 Likes

This one-liner should do it on Ubuntu:

sudo service plexmediaserver stop && sudo sqlite3 /var/lib/plexmediaserver/Library/Application Support/Plex Media Server/Plug-in Support/Databases/com.plexapp.plugins.library.db "UPDATE metadata_items SET added_at = created_at WHERE DATETIME(added_at) > DATETIME('now');" && sudo service plexmediaserver start

Of course you need sqlite3 installed:

sudo apt-get install sqlite3

This worked perfectly, thank you!

1 Like

This was a big help. I use firefox and the there is an add-on called SQL Manager. I also us a Mac mini. So I went into the folder with the .db, made a Duplicate for backup. Then quit Plex, and opened the .db via FireFox Tools. It was easy to find metadata_items and found the table within it to find the values for added_on and then sorted it by that and found that somehow it had incorrect dates for added, 2023 for example. Double clicked to edit the line and was back in happy world.

There was a slight data corruption, but that was very easy fixed within Plex itself. It had duplicated a movie with the same name using a different name. Deleted and recopied.

I’m having the same problem. Ive been using Plex for years. Same TV shows have been in my library for years and yet in the last week, possibly after upgrading to the latest server version but may be un-related, I have old stuff appearing in “Recently Added” when not only is it obvious it hasn’t been recently added but I also know nothing has changed with the media files on my NAS, so its definitely Plex that is screwing up!

@briped said:
This one-liner should do it on Ubuntu:

sudo service plexmediaserver stop && sudo sqlite3 /var/lib/plexmediaserver/Library/Application Support/Plex Media Server/Plug-in Support/Databases/com.plexapp.plugins.library.db "UPDATE metadata_items SET added_at = created_at WHERE DATETIME(added_at) > DATETIME('now');" && sudo service plexmediaserver start

Thanks a lot for posting this – fixed the two episodes in my “Recently added” list that would never go away.

And in case anyone is on macOS and wants to do the same thing, this command should do the trick:

sqlite3 ~/Library/Application\ Support/Plex\ Media\ Server/Plug-in\ Support/Databases/com.plexapp.plugins.library.db "UPDATE metadata_items SET added_at = created_at WHERE DATETIME(added_at) > DATETIME('now');"
1 Like

Hi I receive an error on ubuntu “Error: near “Support”: syntax error” on Mac Mini it works any update?

Ubuntu 16 and later is probably using :

sudo systemctl stop plexmediaserver && sudo sqlite3 /var/lib/plexmediaserver/Library/Application Support/Plex Media Server/Plug-in Support/Databases/com.plexapp.plugins.library.db "UPDATE metadata_items SET added_at = created_at WHERE DATETIME(added_at) > DATETIME('now');" && sudo systemctl start  plexmediaserver 
1 Like

thanks chap!