title: setting type and length on composite-key property in fluent nhibernate
body: <p>In hbm mappings I can</p>
  
  <pre><code>&lt;composite-id&gt;
     [..]
     &lt;key-property name="someStringProperty" 
                   column="somefield" 
                   type="AnsiString" 
                   lenght="8"/&gt;
  &lt;/composite-id&gt;
  </code></pre>
  
  <p>How do I do that (setting type and length) in Fluent?</p>
  
  <p>Edit:<br>
  I posted this on <a href="http://support.fluentnhibernate.org/discussions/help/339-setting-type-and-length-on-composite-key-property" rel="nofollow">support.fluentnhibernate.org</a>. I included some modifications to support setting the type to e.g. AnsiString there.</p>
  
  <p>Edit 2:<br>
  Today Paul Batum has added support for a textual type and a length in his dev-branch. (See <a href="http://github.com/paulbatum/fluent-nhibernate/commit/26f7b11ca908f9f28512298e5dae69fb25051a0e" rel="nofollow">github</a> on the changes.)<br>
  This makes it possible to write </p>
  
  <pre><code>CompositeId()
    .KeyProperty(
         p =&gt; p.SomeProp, 
         k =&gt; k.ColumnName("someField").Type("AnsiString").Length(8))
  </code></pre>