Re: problem with get/setBoost of document fields

2004-09-29 Thread Doug Cutting
Bastian Grimm [Eastbeam GmbH] wrote: that works... but i have to do this setNorm() for each document, which has been indexed up to now, right? there are round about 1 mio. docs in the index... i dont think it's a good idea to perform a search and do it for every doc (and every field of the doc..

Re: problem with get/setBoost of document fields

2004-09-24 Thread Bastian Grimm [Eastbeam GmbH]
thanks doug, that works... but i have to do this setNorm() for each document, which has been indexed up to now, right? there are round about 1 mio. docs in the index... i dont think it's a good idea to perform a search and do it for every doc (and every field of the doc...). is there any possibi

Re: problem with get/setBoost of document fields

2004-09-23 Thread Doug Cutting
You can change field boosts without re-indexing. http://jakarta.apache.org/lucene/docs/api/org/apache/lucene/index/IndexReader.html#setNorm(int,%20java.lang.String,%20byte) Doug Bastian Grimm [Eastbeam GmbH] wrote: thanks for your reply, eric. so i am right that its not possible to change the boost

Re: problem with get/setBoost of document fields

2004-09-23 Thread Bastian Grimm [Eastbeam GmbH]
thanks for your reply, eric. so i am right that its not possible to change the boost without reindexing all files? thats not good... or is it ok only to change the boosts an optimize the index to take changes effecting the index? if not, will i be able to boost those fields in the searcher? than

Re: problem with get/setBoost of document fields

2004-09-23 Thread Erik Hatcher
The boost is not thrown away, but rather combined with the length normalization factor during indexing. So while your actual boost value is not stored directly in the index, it is taken into consideration for scoring appropriately. Erik On Sep 23, 2004, at 8:17 AM, Bastian Grimm [Eastb

Re: problem with get/setBoost of document fields

2004-09-23 Thread Bastian Grimm [Eastbeam GmbH]
hmm ok, but how will i be able to set different boosts to fields, if this value is not stored?! i dont really understand why i can set a boost factor and it is not stored and used. what i want to do, is to weight my searchable index fields (type: Field.UnStored) with a different factors for thos

Re: problem with get/setBoost of document fields

2004-09-22 Thread Daniel Naber
On Wednesday 22 September 2004 18:44, Bastian Grimm [Eastbeam GmbH] wrote: > if i set the d1 and f1 boost Âto 1.0f (default) the score returned by > the HitCollector is 0.3xxx - shouldn't it be exactly 1.0 ? See the documentation for getBoost: "Note: this value is not stored directly with the do

problem with get/setBoost of document fields

2004-09-22 Thread Bastian Grimm [Eastbeam GmbH]
hi all, i have a strange problem with the get and setBoost functions (lucene-1.4.1). i am trying the following code: [...] Document d1 = new Document(); Field f1 = Field.Text("field", "word"); f1.setBoost(2.0f); d1.add(f1); d1.setBoost(3.0f); writer.addDocument(d1); [...] so if i'am right, this m