[mythtv-users] Power recording rule to choose between dual feeds

Michael Rice mikerice1969 at gmail.com
Wed Jan 20 21:44:46 UTC 2010


On Wed, Jan 20, 2010 at 8:21 AM, David Engel <david at istwok.net> wrote:
> On Tue, Jan 19, 2010 at 09:54:43PM -0800, Michael Rice wrote:
>> Thanks David this is almost working.  One wrinkle is my Center Ice
>> lineup does not use consecutive
>> channel numbers:
>>
>> 457 GAME11
>> 458 GAME12
>> 459 GAME13
>> 460 GAME14
>> 461 GAME1
>> 462 GAME2
>> 463 GAME3
>> 464 GAME4
>> 465 GAME5
>> 466 GAME6
>> 467 GAME7
>> 468 GAME8
>> 469 GAME9
>> 470 GAME10
>>
>> So I think I need to convert the callsign to a number and use that
>> instead of the channel.
>> Hopefully I can figure out how to do that.  Or maybe I will just
>> rename the callsigns if
>> I have to.
>
> If you go this route, I suggest you manually rename the "GAME?"
> callsigns to "GAME0?".  That would make parsing out the number much
> easier.  In the example I gave earlier, I initially tried to use the
> callsigns as is, but MySQL's lack of a regexp-based replace made it
> look to be fairly tedious.  I then switched to using channum to
> illustrate the point.

Here's what I have which seems to be working:

priorityname: Leafs Home
recpriority: 1
selectclause: ((program.title = 'NHL Hockey') * (program.subtitle LIKE
'% at Toronto Maple Leafs%') * (channel.channum >= 457 AND
channel.channum <= 470) * (14 - substring(channel.callsign,5)))

priorityname: Leafs Away
recpriority: 1
selectclause: ((program.title = 'NHL Hockey') * (program.subtitle LIKE
'%Toronto Maple Leafs at %') * (channel.channum >= 457 AND
channel.channum <= 470) * (substring(channel.callsign,5) - 1))

priorityname: Leafs HighDef
recpriority: 14
selectclause: program.title = 'NHL Hockey' AND program.subtitle LIKE
'%Toronto%' AND (channel.channum < 457 OR channel.channum > 470)

Look ok?


More information about the mythtv-users mailing list