当前位置: 代码迷 >> Java相关 >> 求助:如何安装sql server2000?
  详细解决方案

求助:如何安装sql server2000?

热度:667   发布时间:2005-07-08 16:05:00.0
求助:如何安装sql server2000?
我在编写与sql数据库连接时,总是出现下面的错误:
java.sql.SQLException: [Microsoft][SQLServer JDBC Driver][SQLServer]用户 'sa' 登
录失败。原因: 未与信任 SQL Server 连接相关联。
        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.TDSLoginRequest.processReplyToken(Un
known Source)
        at com.microsoft.jdbc.sqlserver.tds.TDSRequest.processReply(Unknown Sour
ce)
        at com.microsoft.jdbc.sqlserver.SQLServerImplConnection.open(Unknown Sou
rce)
        at com.microsoft.jdbc.base.BaseConnection.getNewImplConnection(Unknown S
ource)
        at com.microsoft.jdbc.base.BaseConnection.open(Unknown Source)
        at com.microsoft.jdbc.base.BaseDriver.connect(Unknown Source)
        at java.sql.DriverManager.getConnection(DriverManager.java:512)
        at java.sql.DriverManager.getConnection(DriverManager.java:171)
        at CreatTableTest.getConnection(CreatTableTest.java:108)
        at CreatTableTest.main(CreatTableTest.java:28)
Exception in thread "main" java.lang.NullPointerException
        at CreatTableTest.createTable(CreatTableTest.java:41)
        at CreatTableTest.main(CreatTableTest.java:29)
它说明了什么?是不是我的数据库安装的不正确呢!?
搜索更多相关的解决方案: sql  

----------------解决方案--------------------------------------------------------
看看你的sql服务器登陆是否允许sql和windows用户,通常的默认是只允许windows,更改一下即可
----------------解决方案--------------------------------------------------------
  相关解决方案