: I received a report of a problem with posting data to Solr.  The post 
: method is a multi-part form, so if you inspect it, it looks something 
: like this:
        ...
: What's happening, though, when this is posted to Solr is that any 
: semicolons in the data are being interpreted as multi-value separators.  
: So when the above is posted, Solr apparently thinks that 
: "metadata_attribute_name" has 4 values, "abc", "def", "ghi", and "second 
: value", rather than two values, "abc;def;ghi" and "second value".

karl: can you be more specific about how exactly someone can recreate the 
the problem?  specificly: where do you see 4 values?


Using the HTML form below, and submitting to "nc -l "8983" i was able to 
recreate nearly exactly the MIME content you mentioned.  when i killed nc, 
ran the solr example in it's place, and resubmited the form, the 
echoParams output showed me that solr was recognizing the expected two 
values for "metadata_attribute_name" ...

<html>
<head><title>Test of form data</title></head>
<body>
<form method="POST" action="http://localhost:8983/solr/collection1/select"; 
enctype="multipart/form-data">
  <input type="text" name="q" value="solr" />
  <input type="text" name="echoParams" value="all" />
  <input type="text" name="metadata_attribute_name" value="abc;def;ghi" />
  <input type="text" name="metadata_attribute_name" value="second value" />
  <input type="submit"/>
 </form>
</body>
</html>

...

<arr name="metadata_attribute_name"><str>abc;def;ghi</str><str>second 
value</str></arr>



-Hoss

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@lucene.apache.org
For additional commands, e-mail: dev-h...@lucene.apache.org

Reply via email to