www.databasejournal.com/features/oracle/article.php/3442661
December 3, 2004 Here is how to make a connection from Oracle to SQL Server using Oracles heterogeneous Services ODBC agent. Many database shops that have more than just Oracle. In fact, SQL Server is gaining popularity and there are many shops that I know of that have this database system within their walls. Oracle has a generic connectivity methodology that allows for the Oracle database server to access non-Oracle database systems through ODBC and SQL*Net services. This article explores in a step-by-step fashion setting up this connection so that we may query from a SQL Server database. 1. Define a Data Source Name (DSN) for SQL ServerThe first step is to define a system DSN within the Windows ODBC Data Sources.
2. Create a Heterogeneous Services Initialization FileOracle has provided a sample heterogeneous services init file within the $ORACLE_HOME/hs/admin directory. You will need to copy that file to a new file name within the same directory and edit it for the ODBC DSN you have just created. Below you will find the sample heterogeneous services file Oracle provides and then an edited version, which I have given a new name that corresponds to my DSN name. $ORACLE_HOME/hs/admin/inithsodbc.ora sample file # This is a sample agent init file that contains the HS parameters that are needed for an ODBC Agent. # # HS init parameters # HS_FDS_CONNECT_INFO = <odbc data_source_name> HS_FDS_TRACE_LEVEL = <trace_level> # # Environment variables required for the non-Oracle system # #set <envvar>=<value> $ORACLE_HOME/hs/admin/initMYSQLSERVERDSN.ora altered file # This is a sample agent init file that contains the HS parameters that are needed for an ODBC Agent. # # HS init parameters # HS_FDS_CONNECT_INFO = MYSQLSERVERDSN HS_FDS_TRACE_LEVEL = OFF |
| Go to page: 1 2 Next |
|
|
|
|
|
|