tns_name_entry is the Oracle Net connect descriptor specified in the tnsnames.ora file.Īfter creating the database link, refresh and expand the connection in the left pane of SQL Developer. Connect to your database server and execute the CREATE DATABASE LINK statement, as follows: CREATE DATABASE LINK dblink CONNECT TO "username" IDENTIFIED BY "password" USING 'tns_name_entry' ĭblink is the complete database link name. To access an ODBC data source, you must create a database link using a database tool like SQL Developer. (ADDRESS = (PROTOCOL = tcp)(HOST = localhost)(PORT = 1521)) The SID must match the value specified in the listener.ora file. SID_LIST_LISTENER=Īdd a connect descriptor for the gateway to the tnsnames.ora file, which is located in ORACLE_HOME\NETWORK\ADMIN directory. To apply the new settings, stop and restart the Oracle Net Listener service. ORACLE_HOME is the Oracle home directory where the gateway resides. The SID of the gateway ( SID_NAME) must be the same in listener.ora and tnsnames.ora. (ADDRESS = (PROTOCOL = TCP)(HOST = localhost)(PORT = 1521))Īdd an entry to the listener.ora file to start the gateway in response to connection requests. The following example is the address on which the Oracle Net Listener listens ( HOST is the address of the machine on which the gateway is installed): LISTENER = Information about the gateway must be added to the listener.ora configuration file which is located in the ORACLE_HOME\NETWORK\ADMIN\ directory. After creating the file, set the HS_FDS_CONNECT_INFO parameter to the system DSN that you created earlier, for example: HS_FDS_CONNECT_INFO=MySQL Configure Oracle Net ListenerĪfter configuring the gateway, you need to configure Oracle Net Listener to communicate with the Oracle database. You need a separate initialization file for each ODBC data source. The name must be prefixed with init - for example, initMySQL.ora. To create an initialization file for the gateway, copy the sample initialization file and rename it. The sample file initdg4odbc.ora is stored in the ORACLE_HOME\hs\admin directory. Oracle sql developer mysql driver#Configure the Initialization FileĪfter installing the gateway and the ODBC driver for MySQL, create an initialization file for your Oracle Database Gateway for ODBC. The gateway can be installed on the machine running the non-Oracle system, the machine running the Oracle database or on a third machine as a standalone. The non-Oracle system can run on the same machine as the Oracle server or on a different machine. The driver must be installed on the same machine as the gateway. Any ODBC-compatible data source can be accessed using the gateway and the appropriate ODBC driver. The gateway works with an ODBC driver to access non-Oracle systems or other, remote Oracle servers. If your data is stored in a non-Oracle database system or cloud application, and you need to access it from an Oracle Database server, you can create a database link to an Oracle Database Gateway for ODBC. Oracle sql developer mysql how to#This article explains how to configure Oracle Database Gateway for ODBC. Configuring Oracle Database Gateway for ODBC
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |