Jackrabbit uses the default lucene algorithm [1] to calculate the score
for a jcr:contains clause. any other query element will usually return a
score of 1000.
a quick test showed the following for the query:
//*[jcr:contains(.,'apache')] order by @jcr:score descending
jcr:score | text property
----------------------------------------------------------------------
1000 | "Apache Jackrabbit"
848 | "some test jackrabbit apache, apache is great"
350 | "this is a text that is much larger than the first one" +
"and only contains the word apache once."
regards
marcel
[1]
http://lucene.apache.org/java/docs/api/org/apache/lucene/search/Similarity.html
Martin Perez wrote:
Hi.
I'm searching some words on jackrabbit (a month ago release, sorry if this
havs changed) string properties and binary content, and every results come
with a jcr:score of 1000.
What is the followed algorithm? is that result ok? I was expecting something
like an score based on the occurrences or something similar.
Martin