The score field

The score field contains a numeric value that indicates the relevance of a returned document to the search criteria, compared to that of other indexed records. The higher the document score value, the more closely the document matches the criteria.

The document score is a value 0 - 100:
  • 0 indicates no match.
  • 100 is always the score for exact search.
  • 100 is the best possible score for a pattern search.
You can use score to order the returned rows according to how closely they match the search criteria. You can also use the score value in SELECT statements to limit a search by specifying the minimum document score of returned documents, as shown in the following example:
SELECT rc.score, id, description FROM videos
    WHERE etx_contains ( description,
    Row('multimedia document editor' , 
        'PATTERN_TRANS & PATTERN_SUBS'),
    rc # etx_ReturnType) AND
    rc.score > 85 ;

The preceding query specifies that only those documents that have a document score of 85 or better are to be returned.