Uploaded image for project: 'Solr'
  1. Solr
  2. SOLR-4134

Cannot "set" multiple values into multivalued field with partial updates when using the standard RequestWriter.

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 4.0
    • Fix Version/s: 4.1
    • Component/s: clients - java, update
    • Labels:
      None

      Description

      I would like to "set" multiple values into a field using partial updates like so:

      List<String> values = new ArrayList<String>();
      values.add("one");
      values.add("two");
      values.add("three");
      doc.setField(field, singletonMap("set", values));
      

      When using the standard XML-based RequestWriter, you end up with a single value that looks like [one, two, three], because of the toString() calls on lines 130 and 132 of ClientUtils. It works properly when using the BinaryRequestWriter.

        Attachments

        1. SOLR-4134.patch
          8 kB
          Shalin Shekhar Mangar
        2. SOLR-4134.patch
          9 kB
          Shalin Shekhar Mangar
        3. SOLR-4134-nolist-fix.patch
          3 kB
          Shalin Shekhar Mangar

          Issue Links

            Activity

              People

              • Assignee:
                shalinmangar Shalin Shekhar Mangar
                Reporter:
                willbutler Will Butler
              • Votes:
                1 Vote for this issue
                Watchers:
                6 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: