<p>I have an application with a REST style interface that takes XML documents via POST from clients. This application is written in Java and uses XML beans to process the posted message. </p>

<p>The XML schema definition for a field in the message looks like this:</p>

<pre><code>&lt;xs:element name="value" type="xs:string" nillable="true" /&gt;
</code></pre>

<p>How do I send a null value that meets this spec?</p>

<p>I sent <code>&lt;value xsi:nil="true" /&gt;</code>
but this caused the XML parser to barf.</p>

What about
```
<value xsi:nil="true"></value>
```
? That's what's
in the spec
.