Multiple Oracle clients installed, how to choose which one to use?

Author: zdenek.socha@fullsys.cz (sochaz)

Hello, in Uniface .asn file, the correct version of Uniface Oracle connector must be set. But we have several machines (mostly servers), where more than one Oracle client is installed - this is for various reasons. I mean, we need Oracle client 10.2., 11.1 and 11.2 on the same PC. Uniface seems to do *no* check for correct versions. I mean, ORA U7.0 is for Oracle client 11g2. But Uniface itself seems not to check this and incorrect version of Oracle client can be used. I'm trying to "force" the Uniface to use correct version of Oracle client. I have tried the "oracle.key" file in my working directory... in bin directory of Uniface, etc... but nothing helps. That oracle.key file seems to be meant to solve the issue (if you have multiple Oracle homes), since it holds the registry key, where correct "Oracle Home" can be found. All in all, it seems, that Uniface "just" loads the very first oci.dll it finds among PATH variable. My question is... is there any way to tell Uniface to use a concrete Oracle client? Be it "full" client, client integrated with server, instant client or anything. I need to let the PATH variable "as is", I'm looking for a "better" way to tell Uniface to use a different Oracle client (without altering the PATH variable). Regards, Zdeněk PS: I have even tried to place oci.dll into Uniface bin directory (the same directory where uniface.exe is) and put oracle.key there... but it did not help, Uniface was unable to connect to Oracle. I was trying to read both, Oracle documentation and Uniface documentation (ulibrary), but can't find any working solution.

2 Comments

  1. sochaz said Hello, in Uniface .asn file, the correct version of Uniface Oracle connector must be set. But we have several machines (mostly servers), where more than one Oracle client is installed - this is for various reasons. I mean, we need Oracle client 10.2., 11.1 and 11.2 on the same PC. Uniface seems to do *no* check for correct versions. I mean, ORA U7.0 is for Oracle client 11g2. But Uniface itself seems not to check this and incorrect version of Oracle client can be used. I'm trying to "force" the Uniface to use correct version of Oracle client. I have tried the "oracle.key" file in my working directory... in bin directory of Uniface, etc... but nothing helps. That oracle.key file seems to be meant to solve the issue (if you have multiple Oracle homes), since it holds the registry key, where correct "Oracle Home" can be found. All in all, it seems, that Uniface "just" loads the very first oci.dll it finds among PATH variable. My question is... is there any way to tell Uniface to use a concrete Oracle client? Be it "full" client, client integrated with server, instant client or anything. I need to let the PATH variable "as is", I'm looking for a "better" way to tell Uniface to use a different Oracle client (without altering the PATH variable). Regards, Zdeněk PS: I have even tried to place oci.dll into Uniface bin directory (the same directory where uniface.exe is) and put oracle.key there... but it did not help, Uniface was unable to connect to Oracle. I was trying to read both, Oracle documentation and Uniface documentation (ulibrary), but can't find any working solution.

    Interesting question This is one the many reasons we have created a launcher application years ago. We let VB determine the oracle version, and combined with the template asn create a specific asn each time we launch our application. For Uniface 9.6 we asked our clients to update to oracle  client 11 since all older versions are out of support. For Uniface 9.4 we used: {if ORA9}                   ORA     U6.0 {if ORA10}                 ORA     U6.2 {if ORA0001100001}   ORA     U6.3 {if ORA0001100002}   ORA     U6.4 Oracle's standard behaviour is to use the first version that's in the PATH. You could also use a batch-file to launch your app in which you first set the path before starting the application, and thus forcing a certain oracle client  


    Author: wimmme (wim.vaneupen@xperthis.be)
  2. Try copying the whole oracle bin directory into the Uniface bin directory. I think I remember this causing Uniface to find the correct Oracle client version, TNS etc.


    Author: JT (jeremy@tebbutts.net)