日期:2014-05-18  浏览次数:20806 次

那位大虾帮我解决以下一个关于数据库联接的问题
异常:
java.sql.SQLException:   [Microsoft][SQLServer   2000   Driver   for   JDBC][SQLServer]对象名   'wareTable '   无效。
at   com.microsoft.jdbc.base.BaseExceptions.createException(Unknown   Source)
at   com.microsoft.jdbc.base.BaseExceptions.getException(Unknown   Source)
at   com.microsoft.jdbc.sqlserver.tds.TDSRequest.processErrorToken(Unknown   Source)
at   com.microsoft.jdbc.sqlserver.tds.TDSRequest.processReplyToken(Unknown   Source)
at   com.microsoft.jdbc.sqlserver.tds.TDSExecuteRequest.processReplyToken(Unknown   Source)
at   com.microsoft.jdbc.sqlserver.tds.TDSRequest.processReply(Unknown   Source)
at   com.microsoft.jdbc.sqlserver.SQLServerImplStatement.getNextResultType(Unknown   Source)
at   com.microsoft.jdbc.base.BaseStatement.commonTransitionToState(Unknown   Source)
at   com.microsoft.jdbc.base.BaseStatement.postImplExecute(Unknown   Source)
at   com.microsoft.jdbc.base.BasePreparedStatement.postImplExecute(Unknown   Source)
at   com.microsoft.jdbc.base.BaseStatement.commonExecute(Unknown   Source)
at   com.microsoft.jdbc.base.BaseStatement.executeUpdateInternal(Unknown   Source)
at   com.microsoft.jdbc.base.BasePreparedStatement.executeUpdate(Unknown   Source)
at   com.xue.market.DAO.Operation.Update(Operation.java:15)
at   com.xue.market.Servlet.market.doPost(market.java:46)
at   javax.servlet.http.HttpServlet.service(HttpServlet.java:709)
at   javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
at   org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
at   org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
at   org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
at   org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
at   org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
at   org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
at   org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
at   org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
at   org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:856)
at   org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:744)
at   org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
at   org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
at   org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
at   java.lang.Thread.run(Thread.java:595)


数据库联接类:


public   class   GetCon   {
        public   GetCon()   {
        }

        private   Connection   con   =   null;
        public   Connection   Getcon()   {
                try   {
                        Class.forName( "com.microsoft.jdbc.sqlserver.SQLServerDriver ");