On Tue, Jul 31, 2012 at 5:16 PM, Jonatan Fournier
<jonatan.fourn...@gmail.com> wrote:
> Hi,
>
> What is the Java syntax to create an update document?

Currently to update a field in a document with solrj you need to do
something like this:

    doc = new SolrInputDocument();
    doc.addField("id", "unique");
    doc.addField("_version_", version); // this is needed only if
optimistic locking is to be used
    HashMap<String, Object> value = new HashMap<String, Object>();
    value.put("set",100);
    doc.addField("price_f", value);

--
 Sami Siren

Reply via email to