请教一个关于jdbc连接的问题

07-05-17 ziyehanbin

今天我用jdbc连接oracle数据库。

出现以下错误:这应该是没有找到oracle jdbc包中的类。请问 dms是作什么的。应该去哪里下载这个包呢。我在最新版的oracle驱动包中也没发现该类。谢谢:-)

信息: connection properties: {user=study, password=****}

Initial SessionFactory creation failed.java.lang.NoClassDefFoundError: oracle/dms/console/DMSConsole

java.lang.ExceptionInInitializerError

at HibernateUtil.<clinit>(HibernateUtil.java:25)

at Main.main(Main.java:14)

Caused by: java.lang.NoClassDefFoundError: oracle/dms/console/DMSConsole

at oracle.jdbc.driver.DMSFactory.<clinit>(DMSFactory.java:27)

at oracle.jdbc.driver.OracleConnection.createDMSSensors(OracleConnection.java:506)

at oracle.jdbc.driver.OracleConnection.<init>(OracleConnection.java:330)

at oracle.jdbc.driver.OracleDriver.getConnectionInstance(OracleDriver.java:485)

at oracle.jdbc.driver.OracleDriver.connect(OracleDriver.java:337)

at java.sql.DriverManager.getConnection(Unknown Source)

at java.sql.DriverManager.getConnection(Unknown Source)

at org.hibernate.connection.DriverManagerConnectionProvider.getConnection(DriverManagerConnectionProvider.java:110)

at org.hibernate.cfg.SettingsFactory.buildSettings(SettingsFactory.java:68)

at org.hibernate.cfg.Configuration.buildSettings(Configuration.java:1509)

at org.hibernate.cfg.Configuration.buildSessionFactory(Configuration.java:1054)

at HibernateUtil.<clinit>(HibernateUtil.java:21)