Re: Termdocs question

2008-06-24 Thread Chris Hostetter
: : >termDocs = reader.termDocs(term); : >while(termDocs.next()){ : >int index = termDocs.doc(); : >if(reader.document(index).get("id").equals(id)){ : >reader.deleteDocument(index); : >} : >} :

Re: Termdocs question

2008-06-23 Thread Vinicius Carvalho
I'm sorry, the problem was with the way the id was being indexed. It was marked as tokenized, so I when searched for it's untokenized form I was not getting the doc, now everything works fine :) Regards On Sat, Jun 21, 2008 at 2:08 PM, Karl Wettin <[EMAIL PROTECTED]> wrote: > > 20 jun 2008 kl. 1

Re: Termdocs question

2008-06-21 Thread Karl Wettin
20 jun 2008 kl. 18.12 skrev Vinicius Carvalho: Hello there! I trying to query for a specific document on a efficient way. Hi Vinicius, termDocs = reader.termDocs(term); while(termDocs.next()){ int index = termDocs.doc(); if(reader.docume

Re: Termdocs question

2008-06-20 Thread Erick Erickson
A couple of questions: 1> I assume by "not returning any docs" you mean that you never get into your while loop. Is that true? 2> I'm a little suspicious of the field labeled "id" and whether it's at all possible that this is getting confused with the internal Lucene doc ID. This is a

Termdocs question

2008-06-20 Thread Vinicius Carvalho
Hello there! I trying to query for a specific document on a efficient way. My index is structured in a way where I have an id field which is a unique key for the whole index. When I'm updating/removing a document I was searching for my id using a Searcher and a TermQuery. But reading the list it se