I can think of two quick possibilities:
1> Just do a delete by query via XML, something like
<delete><query>specfield:value</query></delete>. You could use curl or put
it on the http request (separate from the delta import). There's an example
of posting via post.jar here: http://lucene.apache.org/solr/tutorial.html
curl example: curl http://localhost:8983/solr/update -F stream.body='your
query here'

2> WARNING: I haven't had occasion to use this, but did you look at
preImportDeleteQuery? See: http://wiki.apache.org/solr/DataImportHandler

<http://wiki.apache.org/solr/DataImportHandler>Best
Erick

On Wed, Nov 24, 2010 at 11:31 PM, Robert Thayer
<robert.tha...@bankserv.com>wrote:

> I am using DIH to load data from distinct locations and include a location
> specific field for faceting and hopefully deleting.  My current invocation
> of the DIH though, deletes all documents.
>
> After a little searching it looks like the proper config / invoke of the
> directUpdateHandler2.deleteByQuery() is what I'm looking but can't find any
> examples of how to do this.
>
> The best would be access at the request line, e.g.,
>
>
> ../solr/locationImport?command=full-import&deleteByQuery=locationField:location&..
>
> Or something like that.  Have already customized a transformer but this is
> after the fact of the delete.
>
> Any pointers are appreciated!
>
> Thanks
>

Reply via email to