2013-07-02 237 views
0

我對MySQL服務器是全新的,但擅長於Java!我知道如何使用Java連接MySQL服務器。最近,我爲我製作了一個簡單的小型MySQL服務器(測試)應用程序。它只是爲了我的知識!我已成功連接到數據庫併成功在我的Java應用程序中使用INSERT和SELECT語句。無法訪問並連接到MySQL服務器數據庫


問題是我的應用程序只運行在安裝了SQL Server 2008R2的筆記本電腦上!我剛查了我的另一臺筆記本電腦我的應用程序,它說以下錯誤:

com.microsoft.sqlserver.jdbc.SQLServerException: The TCP/IP 
connection to the host localhost, port 1433 has failed. Error: 
"Connection refused: connect. Verify the connection properties. 
Make sure that an instance of SQL Server is running on the host 
and accepting TCP/IP connections at the port. Make sure that TCP 
connections to the port are not blocked by a firewall. 

我已經試過此鏈接到目前爲止,還沒有成功的我仍然無法訪問我的數據庫我的另一臺機器上!

 msdn.microsoft.com/en-us/library/ms175043.aspx 

從一個答案我也盡我所能!

  stackoverflow.com/a/12430561/2496503 

從這個答案我已經知道我的SQL Server網絡配置(32位)沒有表現出任何細節/在這裏上面的回答提到的選項是附後的快照! enter image description here

請告訴我,如果它是普通的,但它沒有顯示任何選項!否則我的SQL服務器沒有正確安裝請幫助我給我只是提示我會感謝你!

回答

0

執行這些步驟的TCP/IP網絡配置直到第6步,你的問題將得到解決。

[http://www.visual-paradigm.com/support/articles/solve-sql-server-connection-problem.jsp] [1]