Hi,
The application I am working on is based on Spring 3 and Hibernate (JPA).
If I set "hibernate.hbm2ddl.auto" to "create" the tables are properly created. However, when I switch to "validate" Hibernate crashes saying "org.hibernate.HibernateException: Missing column: id in ESERVICES.BANK". This is understandable since "ESERVICES" is not the user that is configured in my datasource and does not exist. When I use "create" hibernate does use the user that is specified in this datasource. I have no idea where Hibernate gets "ESERVICES" from. "ESERVICES" is another project that I used to work on. It still appears in the project but in no significant places (e.g. package name).
For info my datasource is set in the following way :
<bean id="dataSourceOracle" class="org.apache.commons.dbcp.BasicDataSource"> <property name="driverClassName" value="oracle.jdbc.driver.OracleDriver" /> <property name="url" value="jdbc:oracle:thin:@MDNDSK2001215.datahome.com:1521:orcl" /> <property name="username" value="Appli1" /> <property name="password" value="Appli1" /> <property name="initialSize" value="2" /> <property name="maxIdle" value="5" /> <property name="maxActive" value="10" /> <property name="maxWait" value="10000" /> <property name="validationQuery" value="SELECT 1 FROM DUAL" /> <property name="testWhileIdle" value="true" /> <property name="testOnBorrow" value="true" /> </bean>
Any idea ?
Sylvain
|