首页上一页 1 下一页尾页 5 条记录 1/1页
《Java程序设计自学手册》博客 怎么导入数据库老出错哦 急!!
发表在JavaWeb图书答疑
2009-05-12
是否精华
是
否
版块置顶:
是
否
[font size=2]数据库程序在附件里[/font]
[strong][font face=宋体]我用的是SQL Server2005哦
当运行某一个JSP时就出现,如下:
----数据库加载失败,内容如下:
No suitable driver found for jdbc:sqlserver://127.0.0.1:1433;DatabaseName=db_BlodMay
creatConnectionError!
2009-5-12 19:47:43 org.apache.catalina.core.StandardWrapperValve invoke
严重: Servlet.service() for servlet jsp threw exception
[font color=#FF0000]java.lang.NullPointerException[/font]
at tool.JDBConnection.executeQuery(JDBConnection.java:52)
at dao.ArticleTypeDao.queryArticleType(ArticleTypeDao.java:52)
at org.apache.jsp.back_005fArticleAdd_jsp._jspService(back_005fArticleAdd_jsp.java:104)
at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:384)
at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:320)
at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:266)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:228)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:104)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:216)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844)
at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:634)
at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:445)
at java.lang.Thread.run(Thread.java:619)
No suitable driver found for jdbc:sqlserver://127.0.0.1:1433;DatabaseName=db_BlodMay
creatConnectionError!
[/font][/font][/font][/font][/strong]
[strong][font face=宋体]我用的是SQL Server2005哦
当运行某一个JSP时就出现,如下:
----数据库加载失败,内容如下:
No suitable driver found for jdbc:sqlserver://127.0.0.1:1433;DatabaseName=db_BlodMay
creatConnectionError!
2009-5-12 19:47:43 org.apache.catalina.core.StandardWrapperValve invoke
严重: Servlet.service() for servlet jsp threw exception
[font color=#FF0000]java.lang.NullPointerException[/font]
at tool.JDBConnection.executeQuery(JDBConnection.java:52)
at dao.ArticleTypeDao.queryArticleType(ArticleTypeDao.java:52)
at org.apache.jsp.back_005fArticleAdd_jsp._jspService(back_005fArticleAdd_jsp.java:104)
at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:384)
at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:320)
at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:266)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:228)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:104)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:216)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844)
at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:634)
at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:445)
at java.lang.Thread.run(Thread.java:619)
No suitable driver found for jdbc:sqlserver://127.0.0.1:1433;DatabaseName=db_BlodMay
creatConnectionError!
[/font][/font][/font][/font][/strong]