Thanks Alex and Erik. After using "example/files/update-script.js" , I can able to update document value.
Here is my code function processAdd(cmd) { doc = cmd.solrDoc; var id = doc.getFieldValue("user_number"); doc.setField("user_number ", "Hello"); } But setField append the value instead of over-write it. "user_number": [ "0145", "Hello" ] Thanks, Prabaharan -----Original Message----- From: Erik Hatcher [mailto:erik.hatc...@gmail.com] Sent: 22 June 2016 17:44 To: solr-user@lucene.apache.org Subject: Re: How to configure and use updateRequestProcessorChain for Solr-5.3.1 And also be sure your JVM is compatible with the script you’re using - looks fine besides that “use strict” which I’ve used in an update script. There have been some tribulations with JVM’s and some of the update-script.js’s (specifically under example/files as it uses some tricky JavaScript/Java interactions) - so be sure to check the change log and such if you hit anything JVM related. — Erik Hatcher, Senior Solutions Architect http://www.lucidworks.com <http://www.lucidworks.com/> > On Jun 22, 2016, at 8:07 AM, Alexandre Rafalovitch <arafa...@gmail.com> wrote: > > On 22 June 2016 at 21:28, Rajendran, Prabaharan <rajendra...@dnb.com> wrote: >> function processAdd(cmd) { >> "use strict"; >> var doc = cmd.solrDoc; >> } > > > Did you try not using "use strict"? Seems like a kind of Javascript > feature that may not be implemented by the Java's implementation of > the interpreter. > > Regards, > Alex. > ---- > Newsletter and resources for Solr beginners and intermediates: > http://www.solr-start.com/