Ticket #2415: eitscanner_fix_alphanumeric_channum.diff

File eitscanner_fix_alphanumeric_channum.diff, 1.1 KB (added by Janne <janne-mythtv@…>, 15 years ago)
  • libs/libmythtv/eitscanner.cpp

    old new void EITScanner::StartActiveScan(TVRec * 
    224224        // TODO get input name and use it in crawl.
    225225        MSqlQuery query(MSqlQuery::InitCon());
    226226        query.prepare(
    227             "SELECT min(channum) "
     227            "SELECT channum "
    228228            "FROM channel, cardinput, capturecard, videosource "
    229229            "WHERE cardinput.sourceid   = channel.sourceid AND "
    230230            "      videosource.sourceid = channel.sourceid AND "
    void EITScanner::StartActiveScan(TVRec * 
    236236            "      cardinput.cardid     = :CARDID "
    237237            "GROUP BY mplexid "
    238238            "ORDER BY cardinput.sourceid, mplexid, "
    239             "         atsc_major_chan, atsc_minor_chan ");
     239            "         atsc_major_chan, atsc_minor_chan "
     240            "LIMIT 1 ");
    240241        query.bindValue(":CARDID", rec->GetCaptureCardNum());
    241242
    242243        if (!query.exec() || !query.isActive())