That was exactly it. I added the following line to schema.xml and it now works.

<field name="_version_" type="long" indexed="true" stored="true"/>


On Wed, Sep 5, 2012 at 10:13 AM, Jack Krupansky <j...@basetechnology.com> wrote:
> Check to make sure that you are not stumbling into SOLR-3432: "deleteByQuery
> silently ignored if updateLog is enabled, but {{_version_}} field does not
> exist in schema".
>
> See:
> https://issues.apache.org/jira/browse/SOLR-3432
>
> -- Jack Krupansky
>
> -----Original Message----- From: Paul
> Sent: Wednesday, September 05, 2012 10:05 AM
> To: solr-user
> Subject: Still see document after delete with commit in solr 4.0
>
>
> I've recently upgraded to solr 4.0 from solr 3.5 and I think my delete
> statement used to work, but now it doesn't seem to be deleting. I've
> been experimenting around, and it seems like this should be the URL
> for deleting the document with the uri of "network_24".
>
> In a browser, I first go here:
>
> http://localhost:8983/solr/MYCORE/update?stream.body=%3Cdelete%3E%3Cquery%3Euri%3Anetwork_24%3C%2Fquery%3E%3C%2Fdelete%3E&commit=true
>
> I get this response:
>
> <response>
>  <lst name="responseHeader">
>    <int name="status">0</int>
>    <int name="QTime">5</int>
>  </lst>
> </response>
>
> And this is in the log file:
>
> (timestamp) org.apache.solr.update.DirectUpdateHandler2 commit
> INFO: start
> commit{flags=0,_version_=0,optimize=false,openSearcher=true,waitSearcher=true,expungeDeletes=false,softCommit=false}
> (timestamp) org.apache.solr.search.SolrIndexSearcher <init>
> INFO: Opening Searcher@646dd60e main
> (timestamp) org.apache.solr.update.DirectUpdateHandler2 commit
> INFO: end_commit_flush
> (timestamp) org.apache.solr.core.QuerySenderListener newSearcher
> INFO: QuerySenderListener sending requests to Searcher@646dd60e
> main{StandardDirectoryReader(segments_2v:447 _4p(4.0.0.1):C3244)}
> (timestamp) org.apache.solr.core.QuerySenderListener newSearcher
> INFO: QuerySenderListener done.
> S(timestamp) org.apache.solr.core.SolrCore registerSearcher
> INFO: [MYCORE] Registered new searcher Searcher@646dd60e
> main{StandardDirectoryReader(segments_2v:447 _4p(4.0.0.1):C3244)}
> (timestamp) org.apache.solr.update.processor.LogUpdateProcessor finish
> INFO: [MYCORE] webapp=/solr path=/update
> params={commit=true&stream.body=<delete><query>uri:network_24</query></delete>}
> {deleteByQuery=uri:network_24,commit=} 0 5
>
> But if I then go to this URL:
>
> http://localhost:8983/solr/MYCORE/select?q=uri%3Anetwork_24&wt=xml
>
> I get this response:
>
> <response>
>  <lst name="responseHeader">
>    <int name="status">0</int>
>    <int name="QTime">1</int>
>    <lst name="params">
>      <str name="wt">xml</str>
>      <str name="q">uri:network_24</str>
>    </lst>
>  </lst>
>  <result name="response" numFound="1" start="0">
>    <doc>
>      <str name="name">network24</str>
>      <str name="uri">network_24</str>
>    </doc>
>  </result>
> </response>
>
> Why didn't that document disappear?

Reply via email to