[mythtv] GetProgramGuide does not return the good program list
xavier hervy
xavier.hervy at bluebottle.com
Wed Sep 17 16:58:06 UTC 2008
Hi,
After reading the mythxml.cpp source code , I believe the function
GetProgramGuide does not return the right subset of programs.
the function use the following parameters StartTime, EndTime,
NumOfChannels, StartChanId and Details
At the moment the function return the programs which start at or after
"StartTime" and finish before or at "EndTime"
543 QString sSQL = "WHERE program.chanid >= :StartChanId "
544 "AND program.chanid <= :EndChanId "
545 "AND program.starttime >= :StartDate "
546 "AND program.endtime <= :EndDate "
547 "GROUP BY program.starttime, channel.channum, "
548 "channel.callsign, program.title "
549 "ORDER BY program.chanid ";
To build a programs guide, I would expect the function to return the
program guide between StartTime and EndTime for the channel StartChanId
and the following (NumOfChannels-1) channel(s).
Including:
programs which start before Starttime and finish after EndTime
programs which start at or after Starttime and start before EndTime
programs which ends after Starttime and finish at or before EndTime
as bellow:
WHERE program.chanid >= :StartChanId
AND program.chanid <= :EndChanId
AND (
( program.starttime <= :StartDate AND program.endtime >= :StartDate )
OR
( program.starttime >= :StartDate AND program.endtime > :StartDate )
OR
( program.starttime < :EndDate AND program.endtime <= :EndDate )
)
GROUP BY program.starttime, channel.channum,
channel.callsign, program.title
ORDER BY program.chanid
Do I miss something obvious or should I open a trac ticket and submit a
patch ?
Regards,
Xavier
More information about the mythtv-dev
mailing list