[mythtv] [PATCH] Control duplicates by channel ID
David Engel
david at istwok.net
Mon Aug 6 18:58:32 UTC 2007
On Mon, Aug 06, 2007 at 06:05:16AM -0500, David Shay wrote:
> >I'm not sure
> > PL::FromProgram could do this since the recordid wouldn't be available
> > until after the join.
>
> Right. However, Bruce earlier added code to insert the additional
> check after the query to verify on dupchanid and check the chanid's.
> That still doesn't guarantee the right status for programs in the
> past, though. What about "hardcoding" a forced join on chanid, just
> for FromProgram?
That won't work without other changes. In PruneRedundants, PIs for
some chanids can get removed without ever having a corresponding
oldrecorded entry. Consequently, if the FromProgram join always uses
chanid, there won't always be oldrecorded entries for it to match.
A solution for that is to have PruneReduntants call AddHistory (only
for status changes) before deleting a PI. Then all oldrecstatus joins
on oldrecorded could always use chanid. The downside would be an
increase in the number of oldrecorded entries. I don't particularly
like that, but it might be unavoidable.
David
--
David Engel
david at istwok.net
More information about the mythtv-dev
mailing list