How does Toad detect ORACLE_HOMEs?

Running the latest beta on Windows 10.

My preference is for Toad to always use the 19.8 Instant Client. In my user profile, ORACLE_HOME is set to this directory and the directory is also included in the PATH. The "make this the default home" checkbox has been enabled for all configured connections. Randomly Toad seems to prefer another client installation which I am using primarily for OLE DB support.

How can I prevent Toad from preferring this client over the instant client?

At the moment, I have 5 connections open that are using the instant client, but for some reason the connection dialog is defaulting to the other Oracle Home and won't allow me to change it.

Drop down list box is disabled:
image

Oracle homes:

Regards,
Doug

Toad can use only one oracle home at a time.
So once you've made a connection, that "connect using" is disabled.

Close all your connections, then in the login window you can set the one you want and check "make this the Toad default home".

Note: sometimes the Oracle client DLLs are not properly unloaded, so if you have any errors when attempting to change from one Oracle client to another in the same instance of Toad, try closing Toad completely and then choosing the home you want first after restarting Toad.

The way it should work and my experience are not in alignment.

From a fresh reboot, I launched Toad, highlighted 5 entries in the new connection dialog box and opened connections to these 5 databases. Each were configured to use the instant client and in each 'make this the default home' was selected.

Now a few minutes later, I want to open another connection and all connections seem to be configured to use the other Oracle Home and cannot be changed.

Maybe the multi-select is throwing things off. Does it work as expected if you make a single connection to start with?

I still have Toad up with the initial 5 database connections. I have confirmed using Listdlls64.exe that the DLL in use is from the instant client, yet on the New Connection dialog box, Toad has locked in the Oracle Home that is not being used.

Command line: "C:\Program Files\Quest Software\Toad for Oracle 13.3 Beta\Toad.exe" 

Base                Size      Path
0x0000000004190000  0x9c86000  C:\Program Files\Quest Software\Toad for Oracle 13.3 Beta\Toad.exe
...
0x0000000055970000  0xd1000   D:\instantclient_19_8\oci.dll

I'm trying to reproduce this but not having much luck.

What I can tell you, is that any connection made in Toad while another connection is already made, will use the same Oracle client as the existing connection, regardless of the preferred connection shown in the login grid or the 'make this the default'

The first connection made should take the "default home", if the box is checked, and if not, then it'll take the one in the grid.

If you make a connection that you've never made before, and don't currently have a connection open, the "default" will be used.

To answer your original question, since you want to make this change for all connections, the easiest thing would be, when Toad is not running, to edit Connections.XML

Replace <HOME>path-to-the-home-you-don't-want</HOME>
with <HOME>path-to-the-home-you-want</HOME>

Then next when you restart Toad, before you make a connection, also set the "default"

There were a few legacy Oracle Homes configured in this file going back a few years in addition to the latest Instant Client. Now all connections reference the Instant Client and the problem appears to have been resolved.

Thanks for your help.

Doug

1 Like