在我config.properties我:MSSQL 2008:連接字符串錯誤
url = jdbc:sqlserver://ABC\SQLSERVER2008:1433;databasename=M4E;username=sa;password=123456
driver = com.microsoft.sqlserver.jdbc.SQLServerDriver
,但它沒有正確連接到數據庫。我得到的錯誤:
com.microsoft.sqlserver.jdbc.SQLServerException: The TCP/IP connection to the host ABCSQLSERVER2008, port 1433 has failed. Error: "null. Verify the connection properties, check that an instance of SQL Server is running on the host and accepting TCP/IP connections at the port, and that no firewall is blocking TCP connections to the port.".
當我調試時,它出現ABCSQLSERVER2008,而不是ABC \ SQLSERVER2008,如我所料。
任何人都可以幫助我嗎?
[connectionstrings.com(http://www.connectionstrings.com) – 2013-03-24 09:34:30