Topic: 请教一个jdbc-odbc访问远程服务器上数据库的问题 |
Print this page |
1.请教一个jdbc-odbc访问远程服务器上数据库的问题 | Copy to clipboard |
Posted by: cj1007 Posted on: 2006-09-29 21:51 各位大虾们,我想通过jdbc-odbc的方式访问远程服务器上的sql server2000数据库,上网查阅资料后发现只需要把url改一下即可,于是我把原本为jdbc:odbc:<数据库名>的url改为了jdbc:odbc://localhost:1433/<数据库名>(我想先试一下访问本机),于是就报错了。一下是页面的错误显示: HTTP Status 500 - -------------------------------------------------------------------------------- type Exception report message description The server encountered an internal error () that prevented it from fulfilling this request. exception org.apache.jasper.JasperException org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:372) org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:292) org.apache.jasper.servlet.JspServlet.service(JspServlet.java:236) javax.servlet.http.HttpServlet.service(HttpServlet.java:802) root cause java.lang.NullPointerException org.apache.jsp.index_jsp._jspService(index_jsp.java:64) org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:94) javax.servlet.http.HttpServlet.service(HttpServlet.java:802) org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:324) org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:292) org.apache.jasper.servlet.JspServlet.service(JspServlet.java:236) javax.servlet.http.HttpServlet.service(HttpServlet.java:802) note The full stack trace of the root cause is available in the Apache Tomcat/5.0.28 logs 通过企业管理器我也看到了数据库默认的端口就是1433呀,但是在dos中用netstat -a命令却没有发现1433端口的信息。为什么? |
2.Re:请教一个jdbc-odbc访问远程服务器上数据库的问题 [Re: cj1007] | Copy to clipboard |
Posted by: 九佰 Posted on: 2006-09-30 14:46 把环境和代码贴出来 |
Powered by Jute Powerful Forum® Version Jute 1.5.6 Ent Copyright © 2002-2021 Cjsdn Team. All Righits Reserved. 闽ICP备05005120号-1 客服电话 18559299278 客服信箱 714923@qq.com 客服QQ 714923 |