Joined: Fri Aug 06, 2004 9:44 am Posts: 11
|
hi everybody !
I'm quite new to hibernate, so i need a little help with this problem...
I'm trying to connect to a sapdb and this is my hibernate.properties file:
<property name="hibernate.connection.url">jdbc:sapdb://localhost/mydb</property>
<property name="hibernate.connection.driver_class">com.sap.dbtech.jdbc.DriverSapDB</property>
<property name="hibernate.connection.username">user</property>
<property name="hibernate.connection.password">****</property>
<property name="dialect">net.sf.hibernate.dialect.SAPDBDialect</property>
<property name="hibernate.c3p0.minPoolSize">5</property>
<property name="hibernate.c3p0.maxPoolSize">20</property>
<property name="hibernate.c3p0.timeout">1800</property>
<property name="hibernate.c3p0.max_statement">50</property>
<property name="show_sql">false</property>
<property name="transaction.factory_class">
net.sf.hibernate.transaction.JDBCTransactionFactory
</property>
<property name="hibernate.cache.provider_class">
net.sf.hibernate.cache.HashtableCacheProvider
</property>
<property name="hibernate.hbm2ddl.auto">update</property>
this is the result i get when i try to run my java application:
1574 [main] DEBUG net.sf.hibernate.connection.DriverManagerConnectionProvider - opening new JDBC connection
1574 [main] ERROR net.sf.hibernate.tool.hbm2ddl.SchemaUpdate - could not get database metadata
com.sap.dbtech.jdbc.exceptions.JDBCDriverException: SAP DBTech JDBC: Cannot connect to jdbc:sapdb://localhost/mydb [Restart required].
And then my log4j command introduced after configuring the SessionFactory:
1590 [main] INFO EventManager - Hibernate initialized !!
Really i don't know how to fix this problem... I can initialize the SessionFactory without connecting to the database??
Please help!
Thank you.
|
|