1:<?xml version="1.0" encoding="UTF-8"?>
   2:<!DOCTYPE jbosscmp-jdbc PUBLIC "-//JBoss//DTD JBOSSCMP-JDBC 3.2//EN" "http://www.jboss.org/j2ee/dtd/jbosscmp-jdbc_3_2.dtd">
   3:<jbosscmp-jdbc>
   4:  <defaults>
   5:    <datasource>java:IS346DS</datasource>
   6:    <datasource-mapping>mySQL</datasource-mapping>
   7:  </defaults>
   8:  <enterprise-beans>
   9:    <entity>
  10:      <ejb-name>Track</ejb-name>
  11:      <cmp-field>
  12:        <field-name>id</field-name>
  13:        <auto-increment />
  14:      </cmp-field>
  15:      <entity-command name="get-generated-keys" class="org.jboss.ejb.plugins.cmp.jdbc.keygen.JDBC30GeneratedKeysCreateCommand" />
  16:    </entity>
  17:    <entity>
  18:      <ejb-name>Artist</ejb-name>
  19:      <cmp-field>
  20:        <field-name>id</field-name>
  21:        <auto-increment />
  22:      </cmp-field>
  23:      <entity-command name="get-generated-keys" class="org.jboss.ejb.plugins.cmp.jdbc.keygen.JDBC30GeneratedKeysCreateCommand" />
  24:    </entity>
  25:  </enterprise-beans>
  26:  <relationships>
  27:    <ejb-relation>
  28:      <ejb-relation-name>track-artist</ejb-relation-name>
  29:      <relation-table-mapping>
  30:        <table-name>Track_Artist</table-name>
  31:      </relation-table-mapping>
  32:      <ejb-relationship-role>
  33:        <ejb-relationship-role-name>TrackRelationshipRole</ejb-relationship-role-name>
  34:        <key-fields>
  35:          <key-field>
  36:            <field-name>id</field-name>
  37:            <column-name>track_id</column-name>
  38:          </key-field>
  39:        </key-fields>
  40:      </ejb-relationship-role>
  41:      <ejb-relationship-role>
  42:        <ejb-relationship-role-name>ArtistRelationshipRole</ejb-relationship-role-name>
  43:        <key-fields>
  44:          <key-field>
  45:            <field-name>id</field-name>
  46:            <column-name>artist_id</column-name>
  47:          </key-field>
  48:        </key-fields>
  49:      </ejb-relationship-role>
  50:    </ejb-relation>
  51:  </relationships>
  52:</jbosscmp-jdbc>