[mythtv-users] Error preparing query: insert into recordmatch (:NR7RECID not being expanded)

Jan Ceuleers jan.ceuleers at gmail.com
Sat Apr 21 11:13:30 UTC 2012


Hi there.

My backend won't serve the frontend: the frontend wonders whether I've specified the correct IP address. So I look at the backend's log and this is what I found.

Apologies: I've disabled line wrapping for this post because otherwise the log was being garbled.

Specifically, it seems that for some reason :NR7RECID isn't being expanded (replaced with a value).

Please help?

The log contains the mythtv version; feel free to ask for more info.

2012-04-21 12:59:17.622 mythbackend version: fixes/0.24 [v0.24.2-30-ge9a0ecb] www.mythtv.org
2012-04-21 12:59:17.805 Using runtime prefix = /usr
2012-04-21 12:59:17.876 Using configuration directory = /home/mythtv/.mythtv
2012-04-21 12:59:18.009 Empty LocalHostName.
2012-04-21 12:59:18.081 Using localhost value of zotac
2012-04-21 12:59:18.156 New DB connection, total: 1
2012-04-21 12:59:18.216 Connected to database 'mythconverg' at host: localhost
2012-04-21 12:59:18.288 Closing DB connection named 'DBManager0'
2012-04-21 12:59:18.359 Connected to database 'mythconverg' at host: localhost
2012-04-21 12:59:18.419 Current locale EN_GB
2012-04-21 12:59:18.479 Reading locale defaults from /usr/share/mythtv//locales/en_gb.xml
2012-04-21 12:59:18.580 Current MythTV Schema Version (DBSchemaVer): 1264
2012-04-21 12:59:18.640 ThreadPool:HTTP: Initial 1, Max 25, Timeout 60000
2012-04-21 12:59:18.705 Enabling Upnpmedia rebuild thread.
2012-04-21 12:59:19.972 MythBackend: Starting up as the master server.
2012-04-21 12:59:20.212 New DB connection, total: 2
2012-04-21 12:59:20.268 Connected to database 'mythconverg' at host: localhost
2012-04-21 12:59:20.329 mythbackend: MythBackend started as master server
2012-04-21 12:59:20.392 New DB connection, total: 3
2012-04-21 12:59:20.448 Connected to database 'mythconverg' at host: localhost
2012-04-21 12:59:25.947 New DB scheduler connection
2012-04-21 12:59:26.197 Connected to database 'mythconverg' at host: localhost
2012-04-21 12:59:26.259 Main::Registering HttpStatus Extension
2012-04-21 12:59:26.329 Enabled verbose msgs:  important general
2012-04-21 12:59:26.404 AutoExpire: CalcParams(): Max required Free Space: 20.0 GB w/freq: 15 min
2012-04-21 12:59:28.771 UPnpMedia: BuildMediaMap VIDEO scan starting in :/mnt/disk1/mythtv/videos:
2012-04-21 12:59:29.048 UPnpMedia: BuildMediaMap Done. Found 28 objects
2012-04-21 12:59:29.261 Reschedule requested for id -1.
2012-04-21 12:59:29.373 Error preparing query: INSERT INTO recordmatch (recordid, chanid, starttime, manualid) SELECT record.recordid, program.chanid, program.starttime,  IF(search = 5, record.recordid, 0) FROM (record, program INNER JOIN channel       ON channel.chanid = program.chanid)  WHERE record.recordid = :NR7RECID AND program.manualid = 0 AND ( lower(channel.callsign) in ('2be','bbc1','bbc2','vt4','vtm','een','ketnet/canvas','ned1','ned3')
AND lower(program.category) in ('crime/mystery')
AND lower(title) not like 'csi%miami' ) AND (NOT ((record.dupin & 32) AND program.previouslyshown))  AND (NOT ((record.dupin & 64) AND program.generic > 0))  AND (NOT ((record.dupin & 128) AND (program.previouslyshown                                       OR program.first = 0)))  AND channel.visible = 1 AND ((record.type = 4 OR record.type = 6 OR record.type = 9 OR record.type = 10)  OR  ((record.station = channel.callsign)   AND   ((record.type = 3)    OR   ((TIME_TO_SEC(record.starttime) = TIME_TO_SEC(program.starttime))     AND     ((record.type = 2)      OR     ((DAYOFWEEK(record.startdate) = DAYOFWEEK(program.starttime)       AND       ((record.type = 5)        OR       ((TO_DAYS(record.startdate) = TO_DAYS(program.starttime))         AND (record.type <> 0)        )       )      )     )    )   )  ) ))
2012-04-21 12:59:29.497 Driver error was [2/1052]:
QMYSQL3: Unable to prepare statement
Database error was:
Column 'title' in where clause is ambiguous

2012-04-21 12:59:29.570 DB Error (UpdateMatches3):
Query was:
INSERT INTO recordmatch (recordid, chanid, starttime, manualid) SELECT record.recordid, program.chanid, program.starttime,  IF(search = 5, record.recordid, 0) FROM (record, program INNER JOIN channel       ON channel.chanid = program.chanid)  WHERE record.recordid = :NR7RECID AND program.manualid = 0 AND ( lower(channel.callsign) in ('2be','bbc1','bbc2','vt4','vtm','een','ketnet/canvas','ned1','ned3')
AND lower(program.category) in ('crime/mystery')
AND lower(title) not like 'csi%miami' ) AND (NOT ((record.dupin & 32) AND program.previouslyshown))  AND (NOT ((record.dupin & 64) AND program.generic > 0))  AND (NOT ((record.dupin & 128) AND (program.previouslyshown                                       OR program.first = 0)))  AND channel.visible = 1 AND ((record.type = 4 OR record.type = 6 OR record.type = 9 OR record.type = 10)  OR  ((record.station = channel.callsign)   AND   ((record.type = 3)    OR   ((TIME_TO_SEC(record.starttime) = TIME_TO_SEC(program.starttime))     AND     ((record.type = 2)      OR     ((DAYOFWEEK(record.startdate) = DAYOFWEEK(program.starttime)       AND       ((record.type = 5)        OR       ((TO_DAYS(record.startdate) = TO_DAYS(program.starttime))         AND (record.type <> 0)        )       )      )     )    )   )  ) ))
Bindings were:
:NR7RECID=1413
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 MySQL server version for the right syntax to use near ':NR7RECID AND program.manualid = 0 AND ( lower(channel.callsign) in ('2be','bbc1' at line 1

Thanks, Jan


More information about the mythtv-users mailing list