This document is about the SPSS statistics 19.0 How to configure an ODBC connection to a local Oracle database, as follows:
1, open the remote Oracle Database service, open the following two
2, in the local client, the installation of the Oracle database (version win32_11gr2_client, mainly to install the Oracle ODBC driver), through the PL/SQL Client remote connection to the database, testing is normal.
In the D:\app\Administrator\product\11.1.0\client_1\network\admin directory, create a new Tnsnames.ora file with the following contents:
# Tnsnames.ora Network Configuration file:d:\app\1\product\11.1.0\client_1\network\admin\tnsnames.ora# Generated by Oracle configuration Tools. Myoral = (DESCRIPTION = ( address_list = ( ADDRESS = (PROTOCOL = TCP) (HOST = 132.97.194.13) (PORT = 1521 )) (Connect_data = (service_name = myoral) ) )
If normal, you can:
3, after the SPSS statistics open Select: File-Open database-new query
Select Add ODBC data source:
Click "Add", Pop, and select the database you are using, select "Oracle in Oradb ...", (because I have a database of oracle11g, there is a corresponding driver):
1. The name of the data source (which is used later) 2. Description can be filled in 3. Select the service name of the database (automatically matches the current one if the Tnsnames.ora file is configured correctly) 4. Fill in an existing database user. The rest of the default, when completed, click Test Connection will let you enter the database user's user name and password. Click OK, if the prompt is successful, your configuration is successful, the rest is OK.
The ODBC Configuration window then has one more source, such as:
Finally, you can add data for the database: