1 Reply Latest reply on Oct 23, 2004 10:31 PM by raist_majere

    Another Problem - table mapping

    rajiv_malhotra

      I need to map my enterprise beans to a database table having a different name, and this is what i am trying to do. my jbosscmp-jdbc.xml looks like this.

      ..
       <enterprise-beans>
       <entity>
       <ejb-name>First</ejb-name>
       <table-name>First_Table</table-name>
       <cmp-field>
       <field-name>id</field-name>
       </cmp-field>
       <cmp-field>
       <field-name>master_name</field-name>
       </cmp-field>
       </entity>
       </enterprise-beans>
      
       <create-table>false</create-table>
       <remove-table>false</remove-table>
       <read-only>false</read-only>
       <read-time-out>300000</read-time-out>
      .
      .
      

      But still jboss create and maps it to the "First" table rather than the "first_table".
      I have enterred the same mapping in the ejb-jar.xml. but that too did not work.

      Also i want jboss to restrict not to create tables on startup.
      i have modified the value of create-table> as false. is that enough?

      i have a jboss 3.2 - EJB 1.1 configuration.

      thanks in advance