Java开发网 Java开发网
注册 | 登录 | 帮助 | 搜索 | 排行榜 | 发帖统计  

您没有登录

» Java开发网 » Database/JDBC/SQL/JDO/Hibernate » MS SQL  

按打印兼容模式打印这个话题 打印话题    把这个话题寄给朋友 寄给朋友    该主题的所有更新都将Email到你的邮箱 订阅主题
flat modethreaded modego to previous topicgo to next topicgo to back
作者 如何解决?(未与信任 SQL Server 连接相关联)
ququ_0811





发贴: 17
积分: 0
于 2005-05-19 19:31 user profilesend a private message to usersend email to ququ_0811search all posts byselect and copy to clipboard. 
ie only, sorry for netscape users:-)add this post to my favorite list
请尽量用准确的文字描述作为标题
Your next post without a proper Subject will be removed.

Could you please do a search on this board or google for it before you post?



D:\>java testsql
[Microsoft][SQLServer 2000 Driver for JDBC][SQLServer]用户 '(null)' 登录失败。原
因: 未与信任 SQL Server 连接相关联。java.sql.SQLException: [Microsoft][SQLServer
2000 Driver for JDBC][SQLServer]用户 '(null)' 登录失败。原因: 未与信任 SQL Serv
er 连接相关联。
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.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:525)
at java.sql.DriverManager.getConnection(DriverManager.java:193)
at testsql.main(testsql.java:17)
我在连数据库时遇到上面错误!
我想知道是不是我应该在sql 2000中设置什么吗?


why edited on 2005-05-19 20:07

作者 Re:如何解决?(未与信任 SQL Server 连接相关联) [Re:ququ_0811]
why

問題兒童

总版主


发贴: 4629
积分: 388
于 2005-05-19 20:09 user profilesend a private message to usersend email to whysearch all posts byselect and copy to clipboard. 
ie only, sorry for netscape users:-)add this post to my favorite list
from http://www.cjsdn.net/post/view?bid=10&id=140731 :

Check http://support.microsoft.com/default.aspx?scid=kb;en-us;313100

Basic Connectivity Troubleshooting
These are common error messages that may occur when you try to connect to your SQL server:

java.sql.SQLException: [Microsoft][SQLServer 2000 Driver for JDBC][SQLServer]Login failed for user 'user'. Reason: Not associated with a trusted SQL Server connection.
This error message occurs if the SQL Server 2000 authentication mode is set to Windows Authentication mode. The Microsoft SQL Server 2000 driver for JDBC does not support connecting by using Windows NT authentication. You must set the authentication mode of your SQL Server to Mixed mode, which permits both Windows Authentication and SQL Server Authentication.



Please post your 心得, 总结 like what you suggested on http://www.cjsdn.net/post/view?bid=10&id=143891


why edited on 2005-06-01 18:31

作者 Re:如何解决?(未与信任 SQL Server 连接相关联) [Re:ququ_0811]
ququ_0811





发贴: 17
积分: 0
于 2005-05-21 11:23 user profilesend a private message to usersend email to ququ_0811search all posts byselect and copy to clipboard. 
ie only, sorry for netscape users:-)add this post to my favorite list
经过几天的数据库的连接!我现在已经可连接到我的ms sql
了,也练习了大哥教的方法,效果挺好的!在我刚安装my sql 由于我选这了windows 模式!使我的连接出现问题!由于我的个人版中没找到修改选项,我只好重一边!结果就可以了!如果我们使用工具时,一定要配好环境!
我感觉当我们遇到问题时,一定不要感觉有什么特别的,在我们的学习中这应该很正常,只要我们多接触,多看看别人的经验,问题一一排除,好好的总结,慢慢来就会见到效果!
请大哥多给点指教!
ToungeTounge




flat modethreaded modego to previous topicgo to next topicgo to back
  已读帖子
  新的帖子
  被删除的帖子
Jump to the top of page

   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