web analytics
Understanding Database Link in Oracle Options
codeling
Posted: Monday, April 3, 2017 2:20:33 PM

Rank:Advanced Member
Groups: Member
Joined: 12/11/2015
Posts: 836
Points: 3498

A database link is a schema object in one database that enables you to access objects on another database.The other database need not be an Oracle Database system. However, to access non-Oracle systems you must use Oracle Heterogeneous Services.

After you have created a database link, you can use it to refer to tables and views on the other database. In SQL statements, you can refer to a table or view on the other database by appending @dblink to the table or view name. You can query a table or view on the other database with the SELECT statement. You can also access remote tables and views using any INSERT, UPDATE, DELETE, or LOCK TABLE statement.

Sponsor
Posted: Monday, April 3, 2017 2:20:33 PM
 
codeling
Posted: Monday, April 3, 2017 2:27:06 PM

Rank:Advanced Member
Groups: Member
Joined: 12/11/2015
Posts: 836
Points: 3498

To create a private database link, you must have the CREATE DATABASE LINK system privilege. To create a public database link, you must have the CREATE PUBLIC DATABASE LINK system privilege. Also, you must have the CREATE SESSION system privilege on the remote Oracle database.

create_database_link::=

Description of create_database_link.gif follows
 

dblink_authentication ::=

Description of dblink_authentication.gif follows

 

USING 'connect string'

Specify the service name of a remote database. If you specify only the database name, then Oracle Database implicitly appends the database domain to the connect string to create a complete service name. Therefore, if the database domain of the remote database is different from that of the current database, then you must specify the complete service name.

The following statement defines a shared public database link named remote that refers to the database specified by the service name remote:

CREATE PUBLIC DATABASE LINK remote USING 'remote';

Users browsing this topic
Guest

Forum Jump
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.


© 2017 Digcode.com. All rights reserved.