2010-05-09 27 views
1

使用Visual Studio 2010 10.0.20319.1 RTMRel和SQL Server Express 10.50.1600.1我想添加一個新的SQL Server數據庫的.mdf,不過,我收到以下錯誤:無法添加的App_Data SQL Server數據庫

A network-related or instance-specific error occurred while establishing a connection to SQL Server. The server was not found or was not accessible. Verify that the instance name is correct and that SQL Server is configured to allow remote connections. (provider: SQL Network Interfaces, error: 25 – Connection string is not valid)

我已啓用TCP/IP和命名管道,爲Sql Server添加防火牆例外,我成功地從服務器資源管理器窗口中的VS連接。

如果有人能爲我的問題提供解決方案,我將不勝感激。

謝謝。

+0

錯誤說你的連接字符串無效。所以,檢查你的連接字符串。如果您不確定要查找什麼,請發佈連接字符串。 – Aaronaught 2010-05-09 21:58:06

+0

我開始空白,我沒有任何連接字符串設置;無論如何,我都不知道。 – Interfector 2010-05-10 12:36:28

回答

1

我認爲,SQL Server必須在本地運行,以便能夠創建這些數據庫。

  • 我得到了同樣的錯誤
  • 開始我的地方。\ SQLEXPRESS實例
  • 沒有更多的錯誤,和一個可愛的.mdf文件被創建
+0

我無法驗證答案了,但我會給予加:) – Interfector 2013-03-18 12:46:42

相關問題