DB Link creation - No TNSNAMES.ora. Using LDAP [message #519032] |
Tue, 09 August 2011 01:14 ![Go to next message Go to next message](/forum/theme/orafaq/images/down.png) |
![](//www.gravatar.com/avatar/dd44b73c33827aef943cb948c1143d9d?s=64&d=mm&r=g) |
setsun
Messages: 1 Registered: August 2011 Location: Chennai
|
Junior Member |
|
|
Hi Guys,
I need some help in creating DB Links.
1. While I read the documentation for DB link creation, I found that TNSNAMES.ora entry of the target DB is essential to create the DB link ( in USING clause of the DB link syntax
Incidentally, my organization uses LDAP to resolve/identify the database. In this situation, how can i create the DB linkin
2. I need to create DB link object on schema A to connect to schema B. Both schema A and B are on the same instance.
Something like
create database link link_from_a_2_b
connect to b identified by bpass
using <i dont know what should be given here as said in #1 >
The question I have is : Can a DB link of this sort be created?
I understand that referencing objects in B from A this way is not a ideal method since we can grant permissions to A to access objects in B. However, there is a possiblity that B might be moved to a new instance in future. So if I create a DB link, movement of B across different instance would be much quicker.
Thanks in advance for your assistance in this regard.
Cheers
Arun
|
|
|
|
Re: DB Link creation - No TNSNAMES.ora. Using LDAP [message #519322 is a reply to message #519032] |
Thu, 11 August 2011 01:35 ![Go to previous message Go to previous message](/forum/theme/orafaq/images/up.png) ![Go to next message Go to next message](/forum/theme/orafaq/images/down.png) |
![](//www.gravatar.com/avatar/e1d6f311b3f520a9d56278d3029f6c86?s=64&d=mm&r=g) |
s197oo302
Messages: 50 Registered: January 2011 Location: seoul
|
Member |
![michael.oh78](/forum/theme/orafaq/images/skype.png)
|
|
There's two way to connect by DBlink.
If you already insert remote DB name to tnsnames.ora, you can use alias.
like this
CREATE PUBLIC DATABASE LINK MFS01_LINK
CONNECT TO MFS
IDENTIFIED BY <PWD>
USING 'SPAM1';
but if you don't have tnsnames.ora alias in your local clients or connecting party, you must insert full description in dblink creation scripts
This will be like
CREATE PUBLIC DATABASE LINK ORAMFS_56
CONNECT TO ORAMFS
IDENTIFIED BY <PWD>
USING '(DESCRIPTION=
(ADDRESS=
(PROTOCOL=TCP)
(HOST=xxx.xxx.xxx.xx)
(PORT=1521)
)
(CONNECT_DATA=
(SERVICE_NAME=MMS)))';
[Updated on: Thu, 11 August 2011 01:36] Report message to a moderator
|
|
|
|
|