Install Oracle clients without using PL/SQL

Source: Internet
Author: User

The Oracle client is quite annoying. To deploy applications connected to it, you usually need to install its client first.ProgramIt is required to write the Registry on the target machine. If you are not clean, you may still be stuck in the following: when other programs on your machine depend on the Oracle x64 program, and they are probably not written by you at all, so you do not dare to tamper with the server, but you may need a PL/SQL to execute queries in the same environment, at this time, you still need a no-installation method to solve this problem.

1. Download Oracle Instant Client (32-bit)

Because my PL/SQL only supports 32-bit Oracle, you must download the corresponding 32-bit oracle.

You only need to download instantclient-basic-nt-11.2.0.3.0.zip. Other packages are extended according to different requirements.

: Http://www.oracle.com/technetwork/topics/winsoft-085727.html

2. decompress the package to the target machine (assuming it is a fully-installed Windows Server)

Here I selected this folder: C: \ instantclient_11_2_x86 \

3. Configure tnsnames. ora

Use NotePad to create a new tnsnames. ora file and save it to this path:

C: \ instantclient_11_2_x86 \ Network \ admin \ tnsnames. ora

For details, refer to the following Configuration:

My_xxxserver =
(Description =
(Address = (Protocol = TCP) (host = 10.199.200.102) (Port = 1521 ))
(CONNECT_DATA =
(SID = oravm)
(Server = dedicated)
)
)

4. Extract PL/SQL to the target machine, for example, c: \ Program Files (x86) \ PLSQL developer 9.0.0.1601 \

5. Open PL/SQL. When you log on, click "cancel.

Go to "Preferences" (tools-> preferences), select oracle on the left, and enter "Oracle main directory name" and OCI library address on the right:

6. Complete the above steps, re-open PLSQL, enter the user name and password, and select the correct database.

7. Chinese garbled characters

7.1 Method 1: Set environment variables (global, which may affect other Oracle clients)

"Computer"-> "System Properties"-> "Advanced System settings"-> "system properties/Advanced tab"-> "environment variables"-> "system variables"->" new "->
Variable name: nls_lang
Variable value: Simplified chinese_china.zhs16gbk

7.2 Method 2: Set the Registry (not applicable to instant client or other xcopy clients) (global, which may affect other Oracle clients)

[HKEY_LOCAL_MACHINE \ SOFTWARE \ oracle \ key_xe]
"Nls_lang" = "simplified chinese_china.zhs16gbk"

The key_xe may be different from the Oracle Installation Package and can be adjusted as needed.

7.3 method 3: set it before starting PLSQL (independent, does not affect other Oracle clients)

7.3.1 In the PLSQL installation folder, create a BAT file with the following content:

Set nls_lang = simplified chinese_china.zhs16gbk
Plsqldev.exe

In this example, plsqldev.exe is the PLSQL running file. After executing the bat command, PLSQL developer is automatically started and the user name and password are entered. The Chinese Garbled text problem is usually solved. But directly executing this bat file will lead to a black command line window. Write a VBScript file plsqldev. vbs in the installation directory. The content is as follows:

Createobject ("wscript. Shell"). Run "setchinesecharset. Bat", 0

Run plsqldev. vbs later (you can right-click to send shortcuts to the desktop and change the icon to http://files.cnblogs.com/volnet/plsqldev.ico)

7.3.2 to eliminate the black command line window, you can also directly write the following BAT file:

Set nls_lang = simplified chinese_china.zhs16gbk
StartPlsqldev.exe

In this way, there will be no black command line window. The same method is used to modify the icon.

 

I am also working on how to deploy my own apps using a installation-free approach, and this link is worth looking at: http://www.oracle.com/technetwork/issue-archive/2008/08-nov/o68odpnet-101744.html

For the final study results, see http://www.cnblogs.com/volnet/archive/2012/05/22/2513968.html, which also updates the pl/ SQL developer installation.

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.