Hello All,
I'm trying to connect to a sybase database trough C# code, but I cannot get it to work. I tested the connection first on a ODBC data resource from windows, everything works fine. But now i'm trying to access it directly from the code, and the connection string throws an error:
string DeQuery = "query";
string IDquery = String.Format("query");
AsaConnection EchoConn = new AsaConnection();
EchoConn.ConnectionString = 'Driver=Adaptive Server Anywhere 9.0;ENG=Hostname.Database-Name;UID=username;PWD=password;DBN=Database-Name;LINKS=TCPIP(HOST=hostname.domain)';
EchoConn.Open();
AsaCommand EchoComm = new AsaCommand(DeQuery, EchoConn);
AsaDataReader EchoReader = EchoComm.ExecuteReader();
Executing the code I get an error: Invalid connection string. Error parsing connection parameter string Parameter name: value
Anyone has a solution for this issue?
Thanks!
With kind regards,
Peter Manuel