已有101人关注
<
发表在Java图书答疑 2008-04-19
是否精华
版块置顶:
<P>程序报错入下;自几想了很多,查了很多,解决不了 请高手指点&nbsp;</P>
<P>Exception in thread "AWT-EventQueue-0" org.springframework.dao.DataAccessResourceFailureException: Cannot open connection; nested exception is org.hibernate.exception.JDBCConnectionException: Cannot open connection<BR>Caused by: org.hibernate.exception.JDBCConnectionException: Cannot open connection<BR>&nbsp;at org.hibernate.exception.SQLStateConverter.convert(SQLStateConverter.java:74)<BR>&nbsp;at org.hibernate.exception.JDBCExceptionHelper.convert(JDBCExceptionHelper.java:43)<BR>&nbsp;at org.hibernate.exception.JDBCExceptionHelper.convert(JDBCExceptionHelper.java:29)<BR>&nbsp;at org.hibernate.jdbc.ConnectionManager.openConnection(ConnectionManager.java:420)<BR>&nbsp;at org.hibernate.jdbc.ConnectionManager.getConnection(ConnectionManager.java:144)<BR>&nbsp;at org.hibernate.jdbc.AbstractBatcher.prepareQueryStatement(AbstractBatcher.java:105)<BR>&nbsp;at org.hibernate.loader.Loader.prepareQueryStatement(Loader.java:1561)<BR>&nbsp;at org.hibernate.loader.Loader.doQuery(Loader.java:661)<BR>&nbsp;at org.hibernate.loader.Loader.doQueryAndInitializeNonLazyCollections(Loader.java:224)<BR>&nbsp;at org.hibernate.loader.Loader.doList(Loader.java:2145)<BR>&nbsp;at org.hibernate.loader.Loader.listIgnoreQueryCache(Loader.java:2029)<BR>&nbsp;at org.hibernate.loader.Loader.list(Loader.java:2024)<BR>&nbsp;at org.hibernate.loader.hql.QueryLoader.list(QueryLoader.java:375)<BR>&nbsp;at org.hibernate.hql.ast.QueryTranslatorImpl.list(QueryTranslatorImpl.java:308)<BR>&nbsp;at org.hibernate.engine.query.HQLQueryPlan.performList(HQLQueryPlan.java:153)<BR>&nbsp;at org.hibernate.impl.SessionImpl.list(SessionImpl.java:1106)<BR>&nbsp;at org.hibernate.impl.QueryImpl.list(QueryImpl.java:79)<BR>&nbsp;at org.springframework.orm.hibernate3.HibernateTemplate$29.doInHibernate(HibernateTemplate.java:839)<BR>&nbsp;at org.springframework.orm.hibernate3.HibernateTemplate.execute(HibernateTemplate.java:362)<BR>&nbsp;at org.springframework.orm.hibernate3.HibernateTemplate.find(HibernateTemplate.java:830)<BR>&nbsp;at org.springframework.orm.hibernate3.HibernateTemplate.find(HibernateTemplate.java:822)<BR>&nbsp;at dao.UserDAO.queryObject(UserDAO.java:19)<BR>&nbsp;at dao.UserDAO$$FastClassByCGLIB$$7befd4b.invoke(&lt;generated&gt;)<BR>&nbsp;at net.sf.cglib.proxy.MethodProxy.invoke(MethodProxy.java:149)<BR>&nbsp;at org.springframework.aop.framework.Cglib2AopProxy$DynamicAdvisedInterceptor.intercept(Cglib2AopProxy.java:608)<BR>&nbsp;at dao.UserDAO$$EnhancerByCGLIB$$a6abf36f.queryObject(&lt;generated&gt;)<BR>&nbsp;at Login$3.actionPerformed(Login.java:99)<BR>&nbsp;at javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:1849)<BR>&nbsp;at javax.swing.AbstractButton$Handler.actionPerformed(AbstractButton.java:2169)<BR>&nbsp;at javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel.java:420)<BR>&nbsp;at javax.swing.DefaultButtonModel.setPressed(DefaultButtonModel.java:258)<BR>&nbsp;at javax.swing.AbstractButton.doClick(AbstractButton.java:302)<BR>&nbsp;at javax.swing.AbstractButton.doClick(AbstractButton.java:282)<BR>&nbsp;at Login$2.keyPressed(Login.java:76)<BR>&nbsp;at java.awt.Component.processKeyEvent(Component.java:5446)<BR>&nbsp;at javax.swing.JComponent.processKeyEvent(JComponent.java:2713)<BR>&nbsp;at java.awt.Component.processEvent(Component.java:5265)<BR>&nbsp;at java.awt.Container.processEvent(Container.java:1966)<BR>&nbsp;at java.awt.Component.dispatchEventImpl(Component.java:3955)<BR>&nbsp;at java.awt.Container.dispatchEventImpl(Container.java:2024)<BR>&nbsp;at java.awt.Component.dispatchEvent(Component.java:3803)<BR>&nbsp;at java.awt.KeyboardFocusManager.redispatchEvent(KeyboardFocusManager.java:1810)<BR>&nbsp;at java.awt.DefaultKeyboardFocusManager.dispatchKeyEvent(DefaultKeyboardFocusManager.java:672)<BR>&nbsp;at java.awt.DefaultKeyboardFocusManager.preDispatchKeyEvent(DefaultKeyboardFocusManager.java:920)<BR>&nbsp;at java.awt.DefaultKeyboardFocusManager.typeAheadAssertions(DefaultKeyboardFocusManager.java:798)<BR>&nbsp;at java.awt.DefaultKeyboardFocusManager.dispatchEvent(DefaultKeyboardFocusManager.java:636)<BR>&nbsp;at java.awt.Component.dispatchEventImpl(Component.java:3841)<BR>&nbsp;at java.awt.Container.dispatchEventImpl(Container.java:2024)<BR>&nbsp;at java.awt.Window.dispatchEventImpl(Window.java:1778)<BR>&nbsp;at java.awt.Component.dispatchEvent(Component.java:3803)<BR>&nbsp;at java.awt.EventQueue.dispatchEvent(EventQueue.java:463)<BR>&nbsp;at java.awt.EventDispatchThread.pumpOneEventForHierarchy(EventDispatchThread.java:242)<BR>&nbsp;at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:163)<BR>&nbsp;at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:157)<BR>&nbsp;at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:149)<BR>&nbsp;at java.awt.EventDispatchThread.run(EventDispatchThread.java:110)<BR>Caused by: java.sql.SQLException: [Microsoft][SQLServer 2000 Driver for JDBC]Error establishing socket.<BR>&nbsp;at com.microsoft.jdbc.base.BaseExceptions.createException(Unknown Source)<BR>&nbsp;at com.microsoft.jdbc.base.BaseExceptions.getException(Unknown Source)<BR>&nbsp;at com.microsoft.jdbc.base.BaseExceptions.getException(Unknown Source)<BR>&nbsp;at com.microsoft.jdbc.sqlserver.tds.TDSConnection.&lt;init&gt;(Unknown Source)<BR>&nbsp;at com.microsoft.jdbc.sqlserver.SQLServerImplConnection.open(Unknown Source)<BR>&nbsp;at com.microsoft.jdbc.base.BaseConnection.getNewImplConnection(Unknown Source)<BR>&nbsp;at com.microsoft.jdbc.base.BaseConnection.open(Unknown Source)<BR>&nbsp;at com.microsoft.jdbc.base.BaseDriver.connect(Unknown Source)<BR>&nbsp;at java.sql.DriverManager.getConnection(DriverManager.java:525)<BR>&nbsp;at java.sql.DriverManager.getConnection(DriverManager.java:140)<BR>&nbsp;at org.springframework.jdbc.datasource.DriverManagerDataSource.getConnectionFromDriverManager(DriverManagerDataSource.java:291)<BR>&nbsp;at org.springframework.jdbc.datasource.DriverManagerDataSource.getConnectionFromDriverManager(DriverManagerDataSource.java:277)<BR>&nbsp;at org.springframework.jdbc.datasource.DriverManagerDataSource.getConnectionFromDriverManager(DriverManagerDataSource.java:259)<BR>&nbsp;at org.springframework.jdbc.datasource.DriverManagerDataSource.getConnection(DriverManagerDataSource.java:240)<BR>&nbsp;at org.springframework.orm.hibernate3.LocalDataSourceConnectionProvider.getConnection(LocalDataSourceConnectionProvider.java:81)<BR>&nbsp;at org.hibernate.jdbc.ConnectionManager.openConnection(ConnectionManager.java:417)<BR>&nbsp;... 52 more<BR></P>
分享到:
精彩评论 1
城中狼
学分:0 LV1
2008-05-20
沙发
<P>读者您好:</P>
<P>&nbsp;&nbsp; 请您确认一下是否安装了 数据库SQL Server2000 sp4的补丁。</P>
首页上一页 1 下一页尾页 1 条记录 1/1页
手机同步功能介绍
友情提示:以下图书配套资源能够实现手机同步功能
明日微信公众号
明日之星 明日之星编程特训营
客服热线(每日9:00-17:00)
400 675 1066
mingrisoft@mingrisoft.com
吉林省明日科技有限公司Copyright ©2007-2022,mingrisoft.com, All Rights Reserved长春市北湖科技开发区盛北大街3333号长春北湖科技园项目一期A10号楼四、五层
吉ICP备10002740号-2吉公网安备22010202000132经营性网站备案信息 营业执照