0

Ok, I am using the below query to do a fulltext query search:

SELECT city,state_prefix FROM zip_code3 WHERE MATCH (zip_code,city,state_prefix,state_full) AGAINST ('birmingham al') LIMIT 1;

Now, on my development server this works like a treat, rows with the city as "Birmingham" and the state as "AL" are given the highest scores, that being 9.7016019821167 and another similar record with the same city but from a different state of "IA" is given a score of 5.988482475280762.

However, on the production server it is totally different, both results have an equal score of 6.05505323410034.

This is causing chaos as I only need the first result and that result needs to be the correct city/state.

So I'm wondering why am I getting different results and why does the production servers scoring seem to be out of whack?

4

1 回答 1

0

如果没有看到您的配置文件,很难知道问题出在哪里,所以我会尽力猜测。

我认为问题出在ft_min_word_len上。默认值为 4,因此您的生产服务器可能设置为默认值并忽略该状态。

于 2012-09-24T20:37:54.093 回答