Hi, We have a setup of SolrCloud 4.6. The fields Stored value is true. Now I want to delete a field from indexed document. Is there any way from which we can delete the field?? Field which we are trying to delete(extracted from schema.xml):
<field name="SField2" type="string" indexed="true" stored="true" omitNorms="false" termVectors="false" /> We comment out this field(SField2) entry from schema.xml and reload/optimize index from solr admin UI. Commit the solr index. curl http://<<IP>>:8983/solr/update/json?commit=true Again fired query for the same but the removed field(SField2) is back showing in query result. We followed below link to target the requirement: https://cwiki.apache.org/confluence/display/solr/Updating+Parts+of+Documents https://wiki.apache.org/solr/UpdateJSON we tried another commands to delete the document ID: 1> For Deletion: curl http://localhost:8983/solr/update -H 'Content-type:application/json' -d ' [ { "delete":{ "id":"c7d30e6850c54429b888794f7433e3c5" } } ]' Output: {"responseHeader":{"status":400,"QTime":0},"error":{"msg":"Document is missing mandatory uniqueKey field: id","code":400}} 2> to set null in existing indexed field: curl http://localhost:8983/solr/update -H 'Content-type:application/json' -d ' [ {"id" : "c7d30e6850c54429b888794f7433e3c5","SField2":{"set":null} } ]' output: {"responseHeader":{"status":500,"QTime":0},"error":{"msg":"For input string: \"8888888888\"","trace":"java.lang.NumberFormatException: For input string: \"8888888888\"\n\tat java.lang.NumberFormatException.forInputString(NumberFormatException.java:65) Please Help ! -- View this message in context: http://lucene.472066.n3.nabble.com/Delete-field-in-Solr-tp4131003.html Sent from the Solr - User mailing list archive at Nabble.com.