[mythtv-users] Merge two versions of 'oldrecorded' ?

John Pilkington J.Pilk at tesco.net
Wed Aug 6 15:49:07 UTC 2014


On 06/08/14 15:01, Stephen Worthington wrote:
> On Tue, 05 Aug 2014 19:22:36 +0100, you wrote:
>
>> On 05/08/14 18:57, Greg Oliver wrote:
>>> You should be able to just grep the sql out and pipe it straight in.
>>>
>>> If your db backup is from the mythconverg_backup.pl
>>> <http://mythconverg_backup.pl>:
>>>
>>> zcat <dbBackupFile> | grep oldrecorded | grep INSERT | sed
>>> 's/INSERT/INSERT IGNORE/g 'l mysql -u <db_user> -p<Password> mythconverg
>>>
>>> You'll need to get your db_user and Password from your mythtv config.xml
>>> file.
>>>
>>
>> Thank you :-)  I guess I should squirrel away a few backups and try it
>> out - perhaps in stages - so that I can see what's happening.
>>
>> Cheers,
>>
>> John
>
> Merging the databases like that will only work if all the various
> values used in the oldrecorded table (like, for example,
> channel.chanid in the chanid field and channel.callsign in the station
> field) are the same in both databases.  When I set up my laptop, I
> built its database from a copy of my main MythTV system's database so
> I was sure I had the same values and could do things like that.

Yes, I accept that inconsistencies will arise - for example, several of 
the earliest recordings say they are from a current regional channel, 
although at the time I was living somewhere else, and others come up 
with unhelpful random-looking channel numbers instead of names, but the 
title and subtitles seem unaffected and the result is an improvement on 
what I had yesterday.  Not all of these effects are new. I'm just hoping 
none of Mike's dire DB forebodings apply to this particular table!



More information about the mythtv-users mailing list