We always do a full delete before indexing, this is because for us that is
the only way to be sure that there are no documents in the index that don't
exist anymore.

So delete all, than add all.

To use the delete all, we did the following. We added a field called
dummyDelete. This field always contains the value delete.
Like this
               <field name="dummyDelete">delete</field>

Then to delete all documents we do a request containing:

                <delete><query>dummyDelete:delete</query></delete>

That way all documents are deleted where the field dummyDelete contains
delete => all the documents

Hope this is clear. I am not sure if this is a good solution, but it does
work. :)

Greet,

Thierry

On 25/05/07, Jack L <[EMAIL PROTECTED]> wrote:

Oh, is that the case? One document per request for delete?
I'm about to implement delete. Just want to confirm.

--
Best regards,
Jack

Thursday, May 24, 2007, 12:47:21 PM, you wrote:

> currently no.

> Right now you even need a new request for each delete...


> Patrick Givisiez wrote:
>>
>> can I add and delete docs at same post?
>>
>> Some thing like this:
>>
>> myDocs.xml
>> =====================================
>> <add>
>> <doc><field name="mainId">4</field></doc>
>> <doc><field name="mainId">5</field></doc>
>> <doc><field name="mainId">6</field></doc>
>> </add>
>> <delete><id>1</id></delete>
>> <delete><id>2</id></delete>
>> <delete><id>3</id></delete>
>> =====================================
>>
>> Thanks!
>>
>>
>>
>>


Reply via email to