Hi I use the following code to connect to an orace database in Visual Studio 2008 and it is falling over with the exception of ServerVersion threw an invalid operation exception at line 3:

m_strConnectionString = Settings.GetMandatoryConfig("databases", "SourceDB");
m_strQueryTerminator = Settings.GetConfig("databases", "QueryTerminator");
m_odbConn = new OleDbConnection(m_strConnectionString);
m_sql = new SQL(DatabaseType.AnsiSQL, false);

m_strConnectionString is a valid TNS names connection string and is as follows:

Provider=MSDAORA;Data Source=myDS;User ID=myID;Password=myPW

This has previously worked and is using an IIS web server to host the application. I recently converted it from .Net 1.1 (VS 2003) to .Net 3.5/2 (VS 2008) and can't get it working as yet in VS 2008.


I have been getting the same error as well on an app I am working on.

I have not been able to find much information on the actual problem but my connection is still working and I am receiving data back from my db but I am not sure if I will have problems once I run through IIS instead of locally.

The only thing I can think of is asp 3.5 connection strings have problems with versions 9i and below. I have not tried with our 10g servers so it is only a guess and like I said I have been searching for a few days for info on this error without any luck.