Categories
Oracle DB

Create public or private database links in Oracle DB

Create a public dblink:

<SQL> CREATE PUBLIC DATABASE LINK dblink_name CONNECT TO username IDENTIFIED BY "password" USING 'TNS_name'

Create a private dblink:

<SQL> CREATE DATABASE LINK  dblink_name  CONNECT TO username IDENTIFIED BY "password" USING 'TNS_name';