Hướng dẫn cài đặt oracle client 10

I was having a hard time trying to connect to one of my test databases. It took a lot of trial and error until I realized it was because I was using an Oracle 19c client to connect to an Oracle 11g database—and they are not compatible.

Hướng dẫn cài đặt oracle client 10

What saved me a lot of time in testing and figuring this out was installing different versions of the Oracle instant client rather than having to install the full client for each test.

Instant clients are really helpful when you don't need to install all the utilities and drivers of a full client. It's also helpful when you don't have access to run full clients on the computer you're using – for example, a contractor who is using a loaner laptop. And sometimes, like in my situation, they're just handy to have in order to quickly test compatibility between different client, database, and application versions.

Here are my steps to quickly install an instant client and connect to a database using Toad® for Oracle.

Hướng dẫn cài đặt oracle client 10

How to quickly install an Oracle Instant Client and connect to a database using Toad for Oracle

  1. Visit Oracle.com and search for "instant client" or click here. Download the instant client for Windows. If you’re going to be using a 64-bit version of Toad for Oracle, then you should download and install the 64-bit version of the Instant Client. If you need a 32-bit client, then download that and install 32-bit version of Toad for Oracle.
    Hướng dẫn cài đặt oracle client 10
  2. The latest version is 19.6.0 and basic light package has all you need to connect to a database and run some queries in about a 40 megabyte zip file.
    Hướng dẫn cài đặt oracle client 10
  3. Extract the contents of the zip file to a folder, such as C:\instantclient_19_6
    Hướng dẫn cài đặt oracle client 10
  4. There are several ways to go about this next step and it depends on your version of Windows too. Go into Windows Start Menu or Windows Settings and search for “Environment Variables.” You can use the quick search like shown in my first screenshot. You can edit system environment variables for all users on the computer if you have administrator permissions, or you can just edit environment variables for your current user login account. Searching from Start Menu:
    Hướng dẫn cài đặt oracle client 10
    Searching from Windows Settings:
    Hướng dẫn cài đặt oracle client 10
    For older Windows, you can right click on My Computer (or This PC), and select Properties:
    Hướng dẫn cài đặt oracle client 10
    Then select the Advanced tab, then Environment Variables:
    Hướng dẫn cài đặt oracle client 10
  5. Once you get to the Environment Variables, the top half of the window are variable settings just for your Windows account and the bottom half is for everyone who uses this computer, which you may or may not have access to change. We’ll focus on the top half user variables. In the user variables, select “Path” then click on Edit.
    Hướng dẫn cài đặt oracle client 10
  6. Click on New, and create an entry with the directory where you extract the zip file from step 1. In my case that directory was C:\instantclient_19_6. Then move the entry to the top of the list by clicking on “Move Up”. This makes it easy for Toad to find if you have a lot of entries. It should look something like the following screenshot:
    Hướng dẫn cài đặt oracle client 10
    Click OK and OK again.
  7. Now you can launch Toad for Oracle. It should pick up your Oracle Instant Client if that's the only client you have. Enter your User / Schema, Password, then select the Direct tab and enter in Host, Port, and Service Name or SID. You should get this information from your DBA.
    Hướng dẫn cài đặt oracle client 10
    That should be all you need to connect most of the time. Of course, you may have extra security, firewalls, and settings like languages that you may have to set up. Run select * from dual as a test:
    Hướng dẫn cài đặt oracle client 10
  8. Bonus steps – using a TNSNAMES.ORA file is handy if you’ve got a lot of connections to work with and don't want to manually type them in each, one by one. Place a TNSNAMES.ORA file somewhere on your computer. In my case, I’ll also put it in C:\instantclient_19_6
    Hướng dẫn cài đặt oracle client 10
  9. Go back to the environment variables. This time, select “new” to create a new variable.
    Hướng dẫn cài đặt oracle client 10
  10. Enter the name TNS_ADMIN and point it to the directory where your TNSNAMES.ORA file is.
    Hướng dẫn cài đặt oracle client 10
    Select OK and OK again.
  11. Now when you launch Toad for Oracle you can use the TNS tab and drop down to select your database from your TNSNAMES.ORA file. You can also select TNS Editor to modify your TNSNAMES.ORA file from Toad.
    Hướng dẫn cài đặt oracle client 10

Ta-da. That's it. A light weight, quickly installed Oracle Instant Client to play around with. You can test or keep this instant client. You just won't have access to some utilities like import/export exe, tkprof, data pump, etc – but if you don’t need them, then you’re good to go.

Read more blogs from Mat.

Blog: Oracle 11g/12c Client Install on Windows: Lightweight and Locked Down

Useful resources

Toad for Oracle general information

Technical brief: Top Five Reasons to Choose Toad Over SQL Developer

Case study: Opening doors and creating opportunities with data insights

Have questions, comments?

Head over to theToad for Oracle forum on Toad World®! Chat with the me, the other Toad developers, and lots of experienced users.

Help your colleagues

If you think your colleagues would benefit from this blog, share it now on social media with the buttons located at the top of this blog post. Thanks!

About the Author

Mathew Phan began his career as a technical support engineer for Toad for Oracle soon after graduating from the University of California, Irvine, where he obtained a bachelor's degree in computer and information science. Mat has devoted his entire 14-year career with the Toad family of database solutions and held various positions helping to shape the direction and growth of Toad. Early in his tenure, his focus was on Oracle databases from a developer point of view. Now as a systems consultant, he continues to work with customers to build effective solutions that meet their needs.