[mythtv-commits] Ticket #13500: Deleting channels can orphan references in recorded and oldrecorded
MythTV
noreply at mythtv.org
Wed Nov 6 21:09:23 UTC 2019
#13500: Deleting channels can orphan references in recorded and oldrecorded
------------------------------+---------------------------
Reporter: gigem | Owner: gigem
Type: Developer Task | Status: assigned
Priority: minor | Milestone: 31.0
Component: MythTV - General | Version: v30-fixes
Severity: medium | Resolution:
Keywords: | Ticket locked: 0
------------------------------+---------------------------
Comment (by Klaas de Waal):
As mentioned earlier scanning works OK but looking later at the logs I
found error messages like this:
{{{
2019-11-06 21:59:23.660801 E Error preparing query: SELECT MAX(chanid)
FROM channel AND sourceid = :SOURCEID
2019-11-06 21:59:23.660804 E Driver error was [2/1064]:
QMYSQL3: Unable to prepare statement
Database error was:
You have an error in your SQL syntax; check the manual that corresponds to
your MariaDB server version for the right syntax to use near 'AND sourceid
= ?' at line 1
2019-11-06 21:59:23.660844 E DB Error (Getting chanid for new channel
(2)):
Query was:
SELECT MAX(chanid) FROM channel AND sourceid = 1
Bindings were:
:SOURCEID=1
Driver error was [2/1064]:
QMYSQL: Unable to execute query
Database error was:
You have an error in your SQL syntax; check the manual that corresponds to
your MariaDB server version for the right syntax to use near 'AND sourceid
= 1' at line 1
}}}
The sequence to produce this:
- first delete all channels of the videosource with mysql statement
"delete from channel where sourceid=1;"
- do a "Scan of all existing transports"
- delete all channels with the Delete button in mythtv-setup page Channel
Editor
- do a "Scan of all existing transports"
- do "Insert All" for the new channels found
Now the database errors come.
--
Ticket URL: <https://code.mythtv.org/trac/ticket/13500#comment:3>
MythTV <http://www.mythtv.org>
MythTV Media Center
More information about the mythtv-commits
mailing list