[mythtv-users] videometadata restore error and schema

Nick Rout nick.rout at gmail.com
Wed Jan 28 19:11:26 UTC 2009

On Thu, Jan 29, 2009 at 7:22 AM, Brad DerManouelian
<myth at dermanouelian.com> wrote:
> On Jan 28, 2009, at 10:11 AM, Captain Krypto wrote:
>> Hi all,
>> I am a dumb dumb and accidently dropped my videometadata table from
>> mythconverg.
>> I was trying to restore it from a recent backup and I get the following
>> error when running the command:
>> mysql -u mythtv -pmythtv mythconverg < videometadata.sql
>> ERROR 1064 (42000) at line 3: 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 'LOCK TABLES `videometadata` WRITE' at line 3
>> With the code in question being:
>> -- Table structure for table `videometadata`
>> DROP TABLE IF EXISTS `videometadata`;
>> CREATE TABLE `videometadata` (
>> -- Dumping data for table `videometadata`
>> LOCK TABLES `videometadata` WRITE;
>> /*!40000 ALTER TABLE `videometadata` DISABLE KEYS */;
>> INSERT INTO `videometadata` (`intid`, [...]
>> Does anyone know what the issue with that is?
> Yeah, you're completely missing the table definition. Mine looks like this
> (but don't go by it because I'm running trunk and might have a different
> schema for this table):

the OP said he grepped the whole database backup (mythtv_backup.sql)
for just the parts that say 'Insert into videometadata' - in doing so
he missed the table definition. If he looks at his mythtv_backup.sql
file he should find the table definition relevant for his version.

More information about the mythtv-users mailing list