As mentioned earlier, the server must be configured to force creation of new and update of existing tables created by our entities in our programme.


This can be done by adding a property to the persistence.xml file located in the META-INF of the EJB project. The persistence-unit name is set to devDB and the JTA datasource is set to the JNDI name java:devDS as configured in the Jboss server.




As Jboss uses Hibernate for its persistence provider, we need to add a property named "hibernate.hbm2ddl.auto" with a value of "update".



See what I did here




     


                    

Copyright © 2010 VisualBuilder. All rights reserved