Hello everyone,
   
   I recently decided to perform an experiment. I was using Java to do
string comparison on sometimes large data sets (this would sometimes
take days). A friend of mine at work suggested that I use MySQL's full
text searching. I quickly made the change over and I've found that it is
great, extremely fast and I can see that the scoring is working
perfectly. Well, almost perfectly. My problem is that I find the scores
hard to read. When comparing these two strings "5600 10th Ave" and "5600
10th Ave" I get a score of 5.40898323059082. When I compare these two
strings "Greenacres Grand Slam" and "Greenacres Grand Slam", I get a
score of 9.09278202056885, which I assume to be a perfect match.
However, these scores are hard to program for. I need the scores to be
in a percentage form (0-100, 0-1.0, etc...). 

  I read through the documentation and I found "Zero relevance means no
similarity. Relevance is computed based on the number of words in the
row, the number of unique words in that row, the total number of words
in the collection, and the number of documents (rows) that contain a
particular word." I figure I can use this to take the returned score and
calculate a percentage, but I don't know how. 

  Does anyone know of a simple way to do this? Is there a function
provided for full text searching that I am missing? If not, does anyone
know of a formula I can use to get the percentage of the matches?

  Thanks for any help anyone can provide.

Sincerely,

Eric Berry



-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:    http://lists.mysql.com/[EMAIL PROTECTED]

Reply via email to