title: How to set up "one-to-many" mapping of List objects by XML without index column
body: <p>I can set up "one-to-many" mapping of List objects by using annotations, however using XML is not. Could you tell me how to set up using XML mapping. Any help will be appreciated.</p>
  
  <p>Question. Do I need "INDEX" column when I associate some List objects using XML mapping?</p>
  
  <p>annotation mapping -> It works as expected:</p>
  
  <pre><code>@Entity
  @Table(name = "ITEM")
  public class Item {
  
      @Id
      @Column(name = "ID")
      private Long id;
  
      @Column(name = "NAME")
      private String name;
  
      @OneToMany(targetEntity = ItemDetail.class)
      @JoinColumn(name = "ITEM_ID")
      private List&lt;ItemDetail&gt; itemDetails;
  
  @Entity
  @Table(name = "ITEM_DETAIL")
  public class ItemDetail {
  
      @Id
      @Column(name = "ID")
      private Long id;
  
      @Column(name = "NAME")
      private String name;
  
      @Column(name = "ITEM_ID")
      private Long itemId;
  </code></pre>
  
  <p>XML mapping -> It does not work as expected. "Error parsing XML" error is occurred. It seems to need "INDEX column" information:</p>
  
  <pre><code>&lt;hibernate-mapping&gt;
      &lt;class name="jp.sample.entity.Item" table="ITEM"&gt;
          &lt;id name="id" type="java.lang.Long"&gt;
              &lt;column name="ID" /&gt;
              &lt;generator class="identity" /&gt;
          &lt;/id&gt;
          &lt;property name="name" type="string"&gt;
              &lt;column name="NAME" /&gt;
          &lt;/property&gt;
  
          &lt;list name="itemDetails" cascade="all"&gt;
              &lt;key column="ITEM_ID" /&gt;
              &lt;one-to-many class="jp.sample.entity.ItemDetail" /&gt;
          &lt;/list&gt;
  
      &lt;/class&gt;
  &lt;/hibernate-mapping&gt;
  
  &lt;hibernate-mapping&gt;
      &lt;class name="jp.sample.entity.ItemDetail" table="ITEM_DETAIL"&gt;
          &lt;id name="id" type="java.lang.Long"&gt;
              &lt;column name="ID" /&gt;
              &lt;generator class="identity" /&gt;
          &lt;/id&gt;
          &lt;property name="name" type="string"&gt;
              &lt;column name="NAME" /&gt;
          &lt;/property&gt;
          &lt;property name="itemId" type="java.lang.Long"&gt;
              &lt;column name="ITEM_ID" /&gt;
          &lt;/property&gt;
      &lt;/class&gt;
  &lt;/hibernate-mapping&gt;
  </code></pre>