Wednesday, August 12, 2015

DB Link Creation Command to connect to Oracle Database

CREATE DATABASE LINK XX_DBLINK_NAME CONNECT TO XX_USER IDENTIFIED BY XX_PASSWORD USING ' (DESCRIPTION=
    (ADDRESS=
      (PROTOCOL=TCP)
      (HOST= XX_HOSTNAME)
      (PORT= XX_PORTNO)
    )
    (CONNECT_DATA=
      (SERVICE_NAME= XX_SERVICE_NAME)
    )
  )'
/

In the above command replace:

XX_DBLINK_NAME with new Database Link Name to be created
XX_USER with the database username of the target instance
XX_PASSWORD with database password of the target instance
XX_HOSTNAME with the hostname of the target instance
XX_PORTNO with the port number of the target instance
XX_SERVICE_NAME with the service name of the target instance


Hint: You can replace the TNSNAMES of the target instance you are connecting to after the USING clause in the above statement

No comments:

Post a Comment

SQL Query to Find Oracle Web ADI Importer Package Procedure Name

 SELECT ba.attribute2     wed_adi_package_procedure_name   FROM apps.bne_attributes      ba,        apps.bne_param_lists_b   bplb,        ap...