[mythtv] Duplicated column in recorded in today's cvs?

Fa Yoeu fayoeu at gmail.com
Sat Jul 24 03:15:55 EDT 2004


Just a friendly remind to always backup your db before upgrading myth.
 I had to drop a couple of columns also while doing the upgrade. 
Check here to see exactly the db upgrade is trying to do:
mythtv/libs/libmythtv/dbcheck.cpp (try searching for lastmodified).

On Fri, 23 Jul 2004 14:28:17 -0700, Bruce Markey <bjm at lvcm.com> wrote:
> IvanK. wrote:
> > Replying to myself, this is what I had to do:
> >
> > ALTER TABLE oldprogram DROP COLUMN oldtitle;
> -------------------------^^^^--------^^^^^^^^
> > ALTER TABLE recorded DROP COLUMN lastmodified;
> > ALTER TABLE recorded DROP COLUMN filesize;
> >
> > After that everything was good again.
> 
> Or not. My guess is that mythfilldatabase will fail from
> now on.
> 
> While 1052 ADDs lastmodified and filesize to recorded,
> the ALTER for oldprogram is just to change the airdate to
> DATETIME, and will no re-add the oldtitle column you
> dropped.
> 
> Your title history is now gone, and the table is hozed
> so you should:
> 
> mysql> drop table oldprogram;
> mysql> CREATE TABLE oldprogram (oldtitle VARCHAR(128) NOT NULL PRIMARY KEY, airdate TIMESTAMP NOT NULL);
> 
> You may then want to find your most recent DB backup
> (http://www.mythtv.org/docs/mythtv-HOWTO-21.html#ss21.5)
> and:
> 
> $ grep 'INSERT INTO oldprogram ' mythtv_backup.sql > foo
> $ # sanity check foo
> $ mysql -u mythtv -pmythtv mythconverg < foo
> 
> Hope this helps,
> 
> --  bjm
> 
> 
> _______________________________________________
> mythtv-dev mailing list
> mythtv-dev at mythtv.org
> http://mythtv.org/cgi-bin/mailman/listinfo/mythtv-dev
>


More information about the mythtv-dev mailing list