Changeset 1689


Ignore:
Timestamp:
2000-11-22T14:52:05+13:00 (23 years ago)
Author:
kjm18
Message:

queryresult.is_approx now correct

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/gsdl/src/colservr/mgppsearch.cpp

    r1663 r1689  
    117117 
    118118  queryresult.docs_matched = (int)queryResult.docs.size();
    119   queryresult.is_approx = Exact; //for now - change to reflect actual results
    120  
     119
     120  if (queryresult.docs_matched == (int)queryResult.actualNumDocs) {
     121    queryresult.is_approx = Exact;
     122  }
     123  else if (queryresult.docs_matched < (int)queryResult.actualNumDocs) {
     124    queryresult.is_approx = MoreThan;
     125  }
     126  else {
     127    queryresult.is_approx = Approximate;
     128  }
     129
    121130  docresultclass doc;
    122131  for (int i=0; i<(int)queryResult.docs.size(); i++) {
Note: See TracChangeset for help on using the changeset viewer.