2

I'm trying to use oracle odp xcopy deployment, and an instant oracle client as described in: http://ora-00001.blogspot.com/2010/01/odpnet-minimal-non-intrusive-install.html

The goal is to use oracle without installing anything on the machine.

When I run the code, I get the error: ORA-28547: connection to server failed, probable Oracle Net admin error

When I changed the connection string to have an invalid host or port or sid - it gave me a good error (wrong host, or sid or port) But when it's all ok - I get the ORA-28547.

Here is my code:

 using (var con = new Oracle.DataAccess.Client.OracleConnection(
                //"Data Source=Server;User Id=U;Password=P;Pooling=false;"
                "Data Source=(DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=TCP)(HOST=10.100.51.122)(PORT=1521)))(CONNECT_DATA=(SERVER=DEDICATED)(SERVICE_NAME=orcl)));User Id=U;Password=P;Pooling=false;"
                ))
            {
                con.Open();
                var c = con.CreateCommand();
                c.CommandText = "Select * from tab";
                using (var r = c.ExecuteReader())
                {
                    while (r.Read())
                        Console.Write(r[0]);
                }
            }

Help would be greatly appreciated

Noam
  • 4,472
  • 5
  • 30
  • 47

1 Answers1

3

At the end of the day we downloaded another oracle dll and it solved it.

Initially we used the version that was 30mb, and that one caused Theo problem. Once we replaced it with the version that was 130 mb it solved the problem.

Noam
  • 4,472
  • 5
  • 30
  • 47
  • Adding the multi-language DLL solved the problem here as well. We were connecting from an english server to a german oracle instance. – bic May 24 '16 at 12:15