我正在連接到這個正在工作的這個asp.net應用程序的這個普及服務器上的時間最爲困難。現在,我可以使用visual studio中服務器資源管理器中的連接字符串訪問和查看整個數據庫,但是當我實際運行它時,出現錯誤。這裏是我的代碼:ODBC普及錯誤
String myConnectionString =
"Driver={Pervasive ODBC Client Interface};servername=192.168.1.2;[email protected];";
OdbcConnection myConnection = new OdbcConnection(myConnectionString);
OdbcCommand command = new OdbcCommand(myConnectionString, myConnection);
try
{
myConnection.Open();
OdbcDataReader reader = command.ExecuteReader();
reader.Close();
command.Dispose();
myConnection.Close();
}
catch (OdbcException ex)
{
System.Diagnostics.Trace.WriteLine(ex.Message);
}
下面是當它運行我得到的錯誤:
ERROR [42000] [普及] [ODBC客戶端界面] [LNA] [普及] [ODBC引擎接口]語法錯誤:驅動程序< < ??? >> = {Pervasive ODBC Client Interface}
任何幫助將不勝感激,即使它只是一個瘋狂的猜測,因爲我現在有點絕望。
謝謝
你會得到什麼錯誤? – bmargulies 2011-05-31 18:00:15
你能發佈確切的錯誤信息嗎? – NinjaBomb 2011-05-31 18:00:19