25.7. Salton's Formula (The Scoring Formula)

www.ra.pae.osd.mil/adodcas/  

The standard Salton formula used to assign each score is as follows:

3f(1+log(N/n))

Where... f = the frequency of the search term in the document, N = the total number of "rows in the table" (or documents in the library), and n = the number of rows (or documents) which contain the search term. Score can be between 0 and 100, but the top-scoring document in the query will not necessarily have a score of 100 -- scoring is relative, not absolute. This means that scores are not compatible across indexes, or even across queries on the same index.

Следующие несколько примеров, выполненных самостоятельно, помогут пояснить поведение оператора CONTAINS и получить представление о некоторых дополнительных возможностях контекстного запроса:

29. @simpleq 'Маша AND лампу'

30. @simpleq 'маШа AnD ЛамПу'

31. @simpleq '%аша'

32. @simpleq '%у'

33. @simpleq 'малень%'

34. @simpleq 'м%'

35. @simpleq 'ламп% NOT маша'

36. @simpleq 'NEAR ((лампу, маша) ,3)'

37. @simpleq 'маша ACCUM лампу'

Use the ACCUM operator to search for documents that contain at least one occurrence of any of the query terms. The accumulate operator ranks documents according to the total term weight of a document.

Полный перечень и описания реализованных операторов для составления контекстного запроса по документам (название «оператор» здесь неудачно совпадает с именованием «оператором» самой функции CONTAINS) имеется в документации по Oracle. См. [2], [3].