title: How to force an element to contain only CDATA through XSD
body: <p>My requirement is that any Xml file that will be validated against my schema should conform to following condition.</p>
  
  <p>The OTHERWISE element can contain only CDATA section and nothing else.</p>
  
  <p>Example</p>
  
  <p>Valid XML: <code>&lt;OTHERWISE ContentURI=""&gt;&lt;![CDATA[&lt;html&gt;Good-bye&lt;/html&gt;]]&gt;&lt;/OTHERWISE&gt;</code></p>
  
  <p>Invalid XML: <code>&lt;OTHERWISE ContentURI=""&gt;ABC&lt;/OTHERWISE&gt;</code></p>
  
  <p>I am trying the following:</p>
  
  <p><code>&lt;xs:simpleContent&gt;
        &lt;xs:restriction base="OtherwiseAtt"&gt;
          &lt;xs:pattern value="^&amp;lt;\!\[CDATA\[[a-zA-Z0-9]*\]\]&amp;gt;" /&gt;
        &lt;/xs:restriction&gt;
      &lt;/xs:simpleContent&gt;</code></p>
  
  <p>Any thing can go inside the CDATA. I have put [a-zA-Z0-9]* just for testing purpose.</p>
  
  <p>Please help me out.</p>
  
  <p>Thanks
  Sabri</p>