I am trying to connect to Oracle database on my local machine. I have Visual Studio 2013 and Oracle Express 11g.
Here's my c# code:
String str =
"Data Source=localhost;" +
"Initial Catalog=XE;" +
"User Id=system;" +
"Password=12345;";
SqlConnection conn = new SqlConnection(str);
conn.Open();
However it throws an exception:
An unhandled exception of type 'System.Data.SqlClient.SqlException' occurred in System.Data.dll
Additional information: 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
Does anybody know what's going wrong?
Oracleprovider?SqlConnectionis the SQL Server specific provider - it doesn't work with Oracle ...