0 Replies Latest reply on Sep 7, 2006 4:42 AM by prot prot

    hbm2ddl update problem

    prot prot Newbie

      i am using seam with jboss & hibernate for an EJB3 based portal .. we are using 8 databases here with the same schema ...and pls dont ask me why ;)

      and the problem is: if i add one field to an entity the first two schemas are updated, the rest of them are not ... persistence.xml looks like below

      <persistence-unit name="company1_entity_manager">
       <jta-data-source>java:/OracleCompany1</jta-data-source>
       <properties>
       <property name="hibernate.hbm2ddl.auto" value="update"/>
       <property name="hibernate.dialect" value="org.hibernate.dialect.Oracle9Dialect"/>
       <property name="hibernate.session-factory" value="java:/HibernateSessionFactories/company1SessionFactory"/>
       <property name="hibernate.jdbc.batch_size" value="20"/>
       <property name="hibernate.transaction.factory_class" value="org.hibernate.transaction.JDBCTransactionFactory"/>
      
       <property name="jboss.entity.manager.factory.jndi.name" value="java:/EntityManagerFactories/company1EntityManager" />
       <property name="jboss.entity.manager.jndi.name" value="java:/EntityManager/company1"/>
       </properties>
       </persistence-unit>


      and exactly the same config as above for all schemas (company2, company3, etc)

      and another odd thing.. when i deploy, the JBoss log correctly shows 8 schema-update operations, but all table names are shown as COMPANY1.XXX (instead of COMPANY1, COMPANY2, COMPANY3, etc)

      any ideas?

      many thx in advance
      prot