For about a month I have two items stuck in the recently added list.
After these two items the list updates like usual if I add content to the server, but the first two item never change.
Any hint how to get rid off this?
(This has to be a server issue since this happens on every device)
Yes, the recently added information is on the server. Can you call up the xml for these 2 items? In there you will find a field for āaddedAt=ā and a long number. Can you post the numbers for these 2 items? That is the time the item was added to the database in Unix time. If that is somehow set to a time in the future, they will stay there until that time passes and you add more stuff after. If this is the case, you will need to remove and readd the items so a new date can be used.
Changing the xml file will not help. These are actually generated based on what is in the database. You can view the xml by using Plex Web and going to one of the episodes in the season, along the left, hit the 3 dots, then info. A pop up window will appear, hit the view xml at the bottom. This is just to verify that the added_at date is indeed sometime in the future, which is why the items are stuck. That date hasnāt happened so it will always be listed first until that date finally passes and yo have more items after that date.
The less technical fix is to remove and readd (Plex Dance) all the episodes from these seasons. The technical approach is to fix the entries in the database.
The less technical fix is to remove and readd (Plex Dance) all the episodes from these seasons. The technical approach is to fix the entries in the database.
That worked (only needed first Episode of the season)
Thank you very much
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 @MovieFan.Plex post.
I opened the XML and found out the 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]
As a followup to @n_shay 's very helpful post⦠if you have a lot of items that need fixing, you can do the following. Standard disclaimer applies - I know a lot of SQL from my day job, but not as experienced with SQLLite. Backup your db, and use at your own risk.
ā This will give you all of the rows of items containing an added_at date that is greater than right now. I use this to get a rowcount of how many incorrect add dates I have in my db.
select * from metadata_items where added_at >= date(ānowā)
ā To fix them we are going to do just as before and set the added_at date = to created_at, but instead of running a command for each record (I had several hundred)⦠we are going to do them all in one swoop. This looks at all the records in the metadata_items table, and if the added_at date is after right now, then it sets added_at equal to created_at.
update metadata_items
set added_at = created_at
where added_at >= date(ānowā)
Interesting fact, my weird added_at dates were also 2038. Is it possible that there is a condition that will trigger Plex to auto fill in a date like that? Iāve seen some weird bugs during row creation when using XML or metadata sources in SQL. Maybe its a check that needs to be made on the import side of Plex? I looked at the raw file metadata prior to import, and couldnāt see a 2038 date in there anywhere, so Iām assuming it isnāt a problem with a rip/file. Iād be happy to take a look at the import process if somebody at Plex wanted me to.
The time stored in the database is based on linux epoch time which runs out in 2038. If you are seeing 2038, then the Plex scanner probably ran into an overflow value for the date so it stopped at 2038. If you have a way to reliably recreate 2038 showing up, Iād love to know so we can work around it.
Hey guys, I know this is an old post but Iām having the same issue. Tried checking the XML and so far the first 3 season of 24ā¦seem to be correct. Many of them showing 1291042355 added around 2010ā¦so the dates so far seem to be correct. Do I need to go through the xml for each episode to find the culprit? There are over 120 episodes so didnt really want to do that.
update metadata_items set added_at = added_at>=date(ā1539539786ā) where id=XXXXX;
date added comes from one of those 5 movies stuck there for months.
Could someone explain this is simpler terms. I can install sqlite, I can open the file (in my case in :/opt/appdata/plex/database/Library/Application Support/Plex Media Server/Plug-in Support/Databases) which is I assume ācom.plexapp.plugins.library.dbā ??
select * from metadata_items where added_at >= date(ānowā) shows me ā¦>
ā¦> and sits doing nothing so I enter the rest (one cut/paste or is it 3 commands with CR after each). And nothing except ā¦>
If this is a known problem which it seems to be, I am surprised Devs havenāt fixed or at least got it documented. I mean any entry in the future has to be in error no???
I followed all the linux commands to remove roughly 10 recently added items and it doesnāt appear to be working. Iāve even gone as far as to completely uninstall Plex and reinstall only to find that everything is in the same place. Usually I would be happy about this, but now when things are broken. Also, I would like to know exactly where the database thatās currently be used is actually located. I have a folder labeled ālibraryā where I could follow the path given in the instructions above, but looking over the dates of those files, they havenāt been updated since my install/uninstall/linux cmdlet attemps ect. Iāve looked through all the various areas to try to identify the exact location of the database file in question, and have yet to positively identify where this culprit is. Any help would be appreciated. Iām using a synology.
Iāve had this problem happen after the latest serverupdate, never had any issues before. Now some of the TV-series and movies have an addedAt date = 31.des 2097 (epoch: 4039369200). A friend of mine has also experienced this after the latest release, is this issue being looked into?
Iāve had this problem too with a few of my movies and discovered that the problem, at least for me, is that the āModified Dateā of the file is years in the future. I tried everything, updated the added_at date in the sql db but it would always return to this future date.
It wasnāt until I modified the āModified Dateā of the file itself and re-added to Plex would it finally get āunstuckā.