On Mon, Jul 11, 2011 at 8:28 AM, Andrzej Bialecki <a...@getopt.org> wrote:
> On 7/10/11 2:33 PM, Simon Willnauer wrote:
>>
>> Currently there is no easy way to do this. I would need to think how
>> you can force the index to drop those so the answer here is no you
>> can't!
>>
>> simon
>>
>> On Sat, Jul 9, 2011 at 11:11 AM, Gabriele Kahlout
>> <gabri...@mysimpatico.com>  wrote:
>>>
>>> I've stored the contents of some pages I no longer need. How can I now
>>> delete the stored content without re-crawling the pages (i.e. using
>>> updateDocument ). I cannot just remove the field, since I still want the
>>> field to be indexed, I just don't want to store something with it.
>>> My understanding is that field.setValue("") won't do since that should
>>> affect the indexed value as well.
>
> You could pump the content of your index through a FilterIndexReader - i.e.
> implement a subclass of FilterIndexReader that removes stored fields under
> some conditions, and then use IndexWriter.addIndexes with this reader.
>
> See LUCENE-1812 for another practical application of this concept.

good call andrzej, to make this work I think you need to use lucene
directly so make sure you are on the right version.
simon
>
> --
> Best regards,
> Andrzej Bialecki     <><
>  ___. ___ ___ ___ _ _   __________________________________
> [__ || __|__/|__||\/|  Information Retrieval, Semantic Web
> ___|||__||  \|  ||  |  Embedded Unix, System Integration
> http://www.sigram.com  Contact: info at sigram dot com
>
>

Reply via email to