You are viewing a plain text version of this content. The canonical link for it is here.
Posted to solr-user@lucene.apache.org by eShard <zi...@yahoo.com> on 2013/10/01 17:03:25 UTC

how to manually update a field in the index without re-crawling?

Good morning,
I'm currently using Solr 4.0 FINAL.
I indexed a website and it took over 24 hours to crawl.
I just realized I need to rename one of the fields (or add a new one). 
so I added the new field to the schema,
But how do I copy the data over from the old field to the new field without
recrawling everything?

Is this possible?

I was thinking about maybe putting an update chain processor in the /update
handler but I'm not sure that will work.

Thanks,




--
View this message in context: http://lucene.472066.n3.nabble.com/how-to-manually-update-a-field-in-the-index-without-re-crawling-tp4092955.html
Sent from the Solr - User mailing list archive at Nabble.com.

Re: how to manually update a field in the index without re-crawling?

Posted by Shawn Heisey <so...@elyograg.org>.
On 10/1/2013 9:03 AM, eShard wrote:
> I'm currently using Solr 4.0 FINAL.
> I indexed a website and it took over 24 hours to crawl.
> I just realized I need to rename one of the fields (or add a new one).
> so I added the new field to the schema,
> But how do I copy the data over from the old field to the new field without
> recrawling everything?
>
> Is this possible?
>
> I was thinking about maybe putting an update chain processor in the /update
> handler but I'm not sure that will work.

If you meet all the caveats and limitations, then you can use the atomic 
update functionality to add the new field and delete the old field.  For 
each document, you'll need the value of the uniqueKey and the value of 
the field that you want to essentially rename.

http://wiki.apache.org/solr/Atomic_Updates

If you have not configured your fields in the way described by the 
"caveats and limitations" section of that wiki page, then you will have 
to reindex.  There is no way around that requirement.

Final comment, unrelated to your question: 4.0 is ancient and buggy. 
You're going to need to upgrade before too long.

Thanks,
Shawn