Database entry remains when deleting from DVR

Server Version#: 1.24.5.5173

When deleting a DVR, the corresponding entry in the media_provider_resources table is not deleted.

Empty the library trash, then perform a database optimization (Settings - Server - Manage - Troubleshooting).

Is the record still in the table after this?

Thanks for your quick response. I just ran this again to be sure and the entry is still there.

Oh, I just re-read your first post above. You are deleting a DVR (tuner), not a recorded video, right?
Yes, this is a known issue.

I was wondering a lot. :slight_smile: Okay, thanks. Then I just delete it from the database via the console. I just thought I’d report it, since I hadn’t found anything about the error via the search.

How to delete from the database via console?
What are the relevant commands to delete/modify/add something in the database?
Is there any wiki about this? Thanks

I also delete the entry only because the curl error messages in the log get on my nerves. But it is not necessary for the operation.

I haven’t found a help article that describes this now but it works like this:

/path/to/plex/Plex\ Media\ Server --sqlite "/path/to/your/database/com.plexapp.plugins.library.db" "<SQL Statement>"

The entries are as described in the table “media_provider_resources” - you can show them with "SELECT * FROM media_provider_resources" - delete them with "DELETE FROM media_provider_resources WHERE id = <id>".

To be safe, make a backup beforehand and be sure of what you are doing. :slight_smile:

You need to determine the ID of the record you want to delete. If you place an incorrect syntax here, you could delete the wrong record (or in the unluckiest of cases the whole table).

Sure, i know i need to be careful. Doing backup before is quite good idea. :wink:

In case of automatic channel search problem … is it possible to add new DVR channels manually to DB if all channel parameters are known? This would be really very useful.

Take a look at Plex LiveTV&DVR - Senderliste für DVB-C Hamburg-Südholstein - #13 by OttoKerner

Maybe my description was somehow misleading.
I did not mean the parameters for the channel search.
The modification of the ini was already clear to me.

I mean … is it possible to add the channel parameters which are taken from Plex after channel has been found? If channel is found the parameters will be stored in the database (com.plexapp.plugins.library.db) using the table “media_provider_resources”.

The entry from found channels in the database look like this (example):

<Channel channelIdentifier=““triplet://1:1079:11170"” name=”“ZDFinfo HD”" origin=““Unknown”” param=“”<?xml version="1.0" encoding="UTF-8"?> <tunedata><tt>2</tt><dq>0</dq><dr/><fr>450000</fr><md>0</md><sr>6900000</sr><pl>0</pl><lf>7</lf><l1>0</l1><l2>0</l2><ls>0</ls><pp>0</pp><hz>0</hz><in>0</in><fc>0</fc><t>1079</t><n>1</n><s>11170</s><en>0</en></tunedata> “” drm=““0"” type=”“tv”" signalStrength=““51"” signalQuality=”“0"”/>

My question was if there is any description about how to add this to the database including dependencies if needed?

Sorry, none that I know of.

It seems that stuff about the DVR is being retained when you delete the DVR (such as channel mappings). Maybe that’s to make things convenient if you add the DVR back since, for example, channel scanning can take a long time.

But when people are having trouble because of this retention, perhaps, when deleting the DVR, people should be able to specify that everything related to the DVR be removed. This would certainly be more user friendly that having to go into the SQL shell and delete specific rows from specific tables.

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