I have 5 documents indexed in solr. So now I want to insert a new field in all the documents(i.e 5 documents). Is that possible to insert a new field without reindexing all the documents again?
Asked
Active
Viewed 1,335 times
0
-
1See Atomic Updated here: https://lucene.apache.org/solr/guide/6_6/updating-parts-of-documents.html – Hector Correa Jun 04 '20 at 13:13
-
@HectorCorrea I want to insert a new field in a document's. I think atomic update is for updating the existing field in the document. – Praveen Kumar Jun 04 '20 at 13:39
-
There is no effective difference between updating fields and insert new fields from the document side. You'll have to configure the field by using the schema api or schema.xml, if not running in schemaless mode (so unless you're prototyping, add the field first). The atomic update support is the way to go. – MatsLindh Jun 04 '20 at 15:47
1 Answers
0
You can do updates to document by it's id. There are two types Atomic Updates and In-place Updates.
The first is atomic updates. This approach allows changing only one or more fields of a document without having to re-index the entire document.
The second approach is known as in-place updates. This approach is similar to atomic updates (is a subset of atomic updates in some sense), but can be used only for updating single valued non-indexed and non-stored docValue-based numeric fields.
Here's a link!

Community
- 1
- 1