Choosing Oracle Client Version with Microsoft Managed Oracle Provider For .net

We need to change the Oracle Client that the System.Data.OracleClient uses to connect to our database on a server that has multiple versions of the Oracle Client. A different application on the server that we do not have control over is requiring the default ORACLE_HOME directory to remain an older Oracle 9i version of the client. Because of this, our applications using the Managed Oracle Provider for .net are using the 9i client to connect. We have a planned Oracle upgrade for our Database that will require us to use the new 10g version of the client that is also installed on the server, but is not the Default. We are aware that this is possible with the ODP, ODBC, and other providers, however we have several apps using this provider and we are not looking at upgrading. We are hoping to find a connection string attribute, or minor coding change that will enable select applications to connect through the NON-DEFAULT Oracle 10g client, while the older apps out of our control will still connect through the default Oracle 9i client.

 Thanks

0
stry71
4/22/2009 12:12:13 PM
asp.net.oracle 2269 articles. 0 followers. Follow

6 Replies
1329 Views

Similar Articles

[PageSpeed] 53

As far as I know System.Data.OracleClient simply loads the first OCI.dll it finds in your PATH, so you could use a BAT file to change your path and fire up your app. 

I think you could probably change the "start in" directory for the shortcut as well.

Hope it helps,
Greg

0
greg
4/22/2009 3:00:10 PM

Since this and the other app are ASP.net apps, we did think about changing the environment variables on the global.asax app startup, but it seems like there should be a less hack-like solution.

0
stry71
4/22/2009 4:17:21 PM

You can keep both 9i client and 10g one there to see if everything is smooth for the application. Is it right that you ran the different client on the different PCs?


Many Thanks & Best Regards,
HuaMin Chen

(Mark it as answer if it does help you!)
0
wmec
4/23/2009 3:28:33 AM

Both clients are installed. 9i is the default, but 10g is also installed. Our app's database has been upgraded and we need to connect using the 10g installation. Another application that we do not have control of, uses an older version of Oracle and requires the 9i client. Since 9i is the default this is not a problem for them, but it is for us. We need a way to specifically connect from our asp.net application using System.Data.OracleClient through the 10g installation. Currently, it is defaulting to the 9i install and we can't have this. We know both client installs can live happily on the server, that is not the question, we just need a way to choose which client and asp.net app uses for its connections.

 Thanks,

brian

0
stry71
4/23/2009 2:44:39 PM

If we choose 10g client, we need to make sure that it's 'Home0' that is before 9i one. Then when making the connection, we put the corr. TNS name of that 10g DB.


Many Thanks & Best Regards,
HuaMin Chen

(Mark it as answer if it does help you!)
0
wmec
4/24/2009 1:51:39 AM
We went with our original idea and it's works fine. In the global.asax we set the "Path" environment variable in the application_start to a value from a configuration file containing the path of the Oracle client home install we want to connect through appended to the beginning of the existing Path value.  This affects the application pool running the app only, so if there are other apps in the same pool they will also connect through the non-default Oracle Client. Since each of our apps has its own pool, this works perfectly. 

Environment.SetEnvironmentVariable("Path", string.format("{0};{1}",OracleHomeString, Environment.GetEnvironmentVariable("Path").ToString))

 

 

0
stry71
4/24/2009 1:32:03 PM
Reply:

Similar Artilces:

which is shou i use? Microsoft .NET Framework 1.1 Data Provider for Oracle and the Oracle Data Provider for .NET
Microsoft .NET Framework 1.1 Data Provider for Oracle and the Oracle Data Provider for .NETI am confused?Which is better or which one should I use?BTW, I am going to use .net 2.0 with oracle 9. Can anyone tell me what shou I use for working with oracle database?Thanks very much in advance!Justin Oracle's data provider has more functionality than Microsoft's.If your doing transaction processing you can have SAVEPOINTs, which Microsoft's data provider does not provide.Also, Oracle has PL/SQL Associative Arrays which are very powerful.Oracle also allows you to bind parameters by name and pos...

urgent: .NET Provider for Oracle or Oracle Data Provider for .NET
If I want to access Oracle DB in ASP.NET application, and I am using .NET Provider for Oracle or Oracle Data Provider for .NET, should I have to install OracleClient on my .NET server? Is there other choice? Thank you very much.Johnson Johnson2007:should I have to install OracleClient on my .NET server?  You have to options1. install the ODP.NET on your web serverOR2. put the oracle assemblies in your BIN directory   Hi jimmy,Thank you for you reply. Because I could not find a server right now, I should test it first before I agree or disagree with you, as most articles I...

Return an Oracle Ref Cursor to a .NET DataReader object by using the .NET Managed Provider for Oracle
Hello, I am wondering if anyone in this community knows the shorter way to return an Oracle Ref Cursor to a .NET DataReader object by using the .NET Managed Provider for Oracle, something likereturn (IDataReader) SqlHelper.ExecuteReader(ConnectionString, "GET_ACCOUNT", Id); instead of using the way below (look at the C# code) Stored Procedure create or replace PROCEDURE "GET_ACCOUNT" ( p_ID IN ACCOUNT.ID%type, retCursor OUT SA.MYGEN.sqlcur ) IS BEGIN OPEN retCursor FOR SELECT ID, NAME FROM ACCOUNT WHERE ID = p_ID ; ...

Which .Net Provider for Oracle 9i Microsoft or Oracle
Can anyone provide me pros and cons of provider to access Oracle Database ? I am aware of Microsoft Provider and Oracle Provider. Microsoft http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dndotnet/html/manprooracperf.asp Oracle http://otn.oracle.com/software/tech/windows/odpnet/utilsoft.html I guess you can use either. But as some post suggests, if both installed, then MS ODP will not work. I've been using DataDirect Technologies Connect for .Net and Oracle. It's not free, so it depends on your budget. The speed improvements were great for us, and it's ni...

.NET Oracle Provider
Hi all,I am using .NET 2.0 Frameworks Oracle provider and it does not have a OracleDbTypes Type for me to use. I would like to create a parameter that is of the Oracle type NVARCHAR, but it seems I can only use DbTypes, which does not have this. If I used DbTypes.String, would this be ok, otherwise, how else can I be more specific about the Oracle Parameter data type?Thanks  can u explain which type of data u r going to storeThank uBaba Thank uBabaPlease remember to click "Mark as Answer" on this post if it helped you. What's your version of ODP? You have OracleD...

Where can I get native PB drivers for ( Oracle Version 8.0.0.5) with Oracle Net Client Version 7.3.3
( Oracle Version 8.0.0.5) with Oracle Net Client Version 7.3.3 with SQL *Net version 2.x , 32 bit implementation. All versions of PB Enterprise (5,6,7) have the native O73 driver. If you have PB Professional, you can only use ODBC to connect to Oracle. -- Terry Dykstra (TeamSybase) Canadian Forest Oil Ltd. Check out Sybase Developer's Network: http://www.sybase.com/sdn Veena Madhavi <bveenamadhavi@hotmail.com> wrote in message news:38A8FD91.6218D227@hotmail.com... > ( Oracle Version 8.0.0.5) with Oracle Net Client Version 7.3.3 with SQL > *Net version 2...

How call a Oracle Function using Microsoft .Net Oracle Client (System.Data.OracleClient)?
I try to call Oracle Function in .net C# by using System.Data.OracleClient. But i am not successful. Here is my code FUNCTION TTHAO_MONTT_EXISTS ( vten varchar2) RETURN boolean IS ret boolean; montt_id integer; BEGIN ret:=false; montt_id:= -1; select monthethao_id into montt_id from TTHAO_MONTHETHAO where ten = vten; if montt_id!=-1 then ret:=true; end if; return ret; Exception when others then return false; END; I do not know, when I call function TTHAO_MONTT_E...

Oracle ODP.net mulitple Oracle Client
To connect to the oracle database using ODP.net, the applicate must add the dll file called Oracle.DataAccess. There are a lot of version of Oracle.DataAccess. As I know, if the client use Oracle Client 10g Release 2. If the client use Oracle Client 10g Release 2, the application also have to use the Oracle.DataAccess the come from Oracle Client 10g Release 2.  My question is that there are any method to add more than one Oracle.DataAccess version in my product to support multiple OracleClient.   That should automatically happen for the most part.  Oracle's ODP.NET i...

DBD::Oracle and oracle client versions
Is anything 'baked-in' from the oracle environment to a DBD:Oracle install at the time of installation? I'm having some weird problems involving linked databases that MAY be related to the oracle client libraries version; can I change the libraries that DBD:Oracle uses just by changing LD_LIBRRY_PATH and ORACLE_HOME? -- Bruce Johnson University of Arizona College of Pharmacy Information Technology Group Institutions do not have opinions, merely customs On Wed, Aug 27, 2008 at 11:41 AM, Bruce Johnson <johnson@pharmacy.arizona.edu> wrote: > ...

Oracle Spatial support in Devart's ADO.NET Data Provider for Oracle [Edit]
dotConnect for oracle v. 7.3 http://www.devart.com/dotconnect/oracle/ , ADO.NET Provider from Devart, includes support for Oracle Spatial in the projects, using Entity Framework. Devart Team constantly implements all the available Entity Framework innovations, and shortly after the introduction of DbGeometry and DbGeography classes in Entity Framework 5 has implemented support for Oracle Spatial in the Entity Framework provider for Oracle. Oracle MDSYS.SDO_GEOMETRY object type can now be mapped to DbGeometry and DbGeography classes. Now dotConnect for Oracle includes new versions of Devar...

Version of Oracle ODP.NET client?
Does DW.NET 2.0 require a specific version of the ODP.NET client? I just installed the latest version from the Oracle site (10.2.02) and I am getting a strange exception on AdoTrans.BindConnection: System.InvalidCastException: Unable to cast object of type 'Oracle.DataAccess.Client.OracleConnection' to type 'Oracle.DataAccess.Client.OracleConnection'. at Sybase.PowerBuilder.Db.Block.OraBlock.GetConnect(Object[] input, Dbms& dbms, DBVersion& dbVer, String& user) at Sybase.PowerBuilder.Db.DbRoutine.GetConnect(DbDrivers type, Object[] input, ...

Oracle managed provider for .Net 2.0
Does ADO.Net 2.0 comes with Oracle Managed Provider too? If it's so, which is better to use, Oracle Managed Provider developed by Microsoft or by Oracle? In ADO.Net 2.0 can I use data paging (bring only the ammount of data that will be shown on the actual page instead of bringing all the data every time we change the actual page)? How can I do this using Oracle 10g?Juliano NunesMCAD | MCP | Microsoft Student Partnerhttp://julianonetfox2.spaces.live.com (Does ADO.Net 2.0 comes with Oracle Managed Provider too? If it's so, which is better to use, Oracle Managed Provider developed by Microso...

MS Oracle Data Provider, Oracle Instant Client
I have seen very few posts about this, but I have to believe that it is possible.Does anyone know if you can connect to an Oracle DB using the Oracle Instant Client and the MS Oracle Data Provider? Downloading the Oracle Client can leave quite a large footprint on some servers. Thanks in advance!  Yes it is possible to connect to Oracle using Oracle Instant Client without having Oracle Client on the machine. Currently Oracle Instant Client doesn't contain ODP.Net, Oracle is planning to release ODP.Net with Oracle Instant Client which in Beta version now. You can get more in...

DBD-Oracle and Oracle versions
From lurking around this mail list over the years, I've seen numerous items relating to building=20 DBD-Oracle against a specific version of the Oracle client software on *nix systems. =20 Example: if DBD-Oracle was built using version 9,=20 then the Oracle client is upgraded to 10g;=20 it is necessary to rebuild DBD-Oracle with the 10g client. =20 I have used Perl on HP/UNIX, AIX, Linux and Windows. On the *nix systems, Perl came with the OS and I have had to install the DBI and DBD-Oracle modules using=20 the standard make process. On windows, I used=20 ActiveState Activ...

Web resources about - Choosing Oracle Client Version with Microsoft Managed Oracle Provider For .net - asp.net.oracle

Microsoft - Wikipedia, the free encyclopedia
Albuquerque , New Mexico , U.S. (April 4, 1975 ( 1975-04-04 ) ) Microsoft Redmond Campus , Redmond, Washington , U.S. is an American multinational ...

Microsoft Corporation
Visit Microsoft Australia to download themes, find a new PC, upgrade Windows and much more.

Microsoft Canada - Software - Advertising - Phones - IT - Cloud
Microsoft Canada is a world leader in software, services, partner resources and Internet technologies. Get product information, support, and ...

Free Microsoft Points - Free Microsoft Points
Get Free Microsoft Points, Free 1400 Microsoft Points, Free 2100 Microsoft Points codes emailed to you for Free. Yes, All for Free.


Microsoft Bob - Just a short, simple blog for Bob to share some tips and tricks.
Just a short, simple blog for Bob to share some tips and tricks.

Microsoft New England Research and Development Center
The Microsoft New England Research & Development Center is a research and software innovation campus located in the heart of Cambridge, Massachusetts. ...

Jobs at Microsoft - Explore Microsoft Jobs and Join our Talent Community - Apply for Microsoft Jobs Online ...
Search for Jobs at Microsoft here. Explore worldwide Microsoft jobs, including game design jobs, developer jobs, software sales jobs, marketing ...

Microsoft Cloud Partner - Home
... your existing Internal Use Right through June 2013 while you work towards earning Cloud Accelerate status. Note: If you intend to sell Microsoft ...

Microsoft Hohm Service Discontinuation
Microsoft-Hohm discontinuation message

Resources last updated: 12/16/2015 6:52:21 PM