Is this possible to do? If so, how?
On 7/25/11, Brian Lamb <brian.l...@journalexperts.com> wrote: > Yes and that's causing some problems in my application. Is there a way to > truncate the 7th decimal place in regards to sorting by the score? > > On Fri, Jul 22, 2011 at 4:27 PM, Yonik Seeley > <yo...@lucidimagination.com>wrote: > >> On Fri, Jul 22, 2011 at 4:11 PM, Brian Lamb >> <brian.l...@journalexperts.com> wrote: >> > I've noticed some peculiar scoring issues going on in my application. >> > For >> > example, I have a field that is multivalued and has several records >> > that >> > have the same value. For example, >> > >> > <arr name="references"> >> > <str>National Society of Animal Lovers</str> >> > <str>Nat. Soc. of Ani. Lov.</str> >> > </arr> >> > >> > I have about 300 records with that exact value. >> > >> > Now, when I do a search for references:(national society animal >> > lovers), >> I >> > get the following results: >> > >> > <id>252</id> >> > <id>159</id> >> > <id>82</id> >> > <id>452</id> >> > <id>105</id> >> > >> > When I do a search for references:(nat soc ani lov), I get the results >> > ordered differently: >> > >> > <id>510</id> >> > <id>122</id> >> > <id>501</id> >> > <id>82</id> >> > <id>252</id> >> > >> > When I load all the records that match, I notice that at some point, >> > the >> > scores aren't the same but differ by only a little: >> > >> > 1.471928 in one and the one before it was 1.471929 >> >> 32 bit floats only have 7 decimal digits of precision, and in floating >> point land (a+b+c) can be slightly different than (c+b+a) >> >> -Yonik >> http://www.lucidimagination.com >> >