Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.server -> Re: Database Link question
Dante,
I'm afraid Sean is right. As taken from the documentation for GLOBAL_NAMES:
GLOBAL_NAMES Default value: FALSE
Range of values: TRUE/FALSE
This parameter determines whether or not a database link is required to have the same name as the database to which it connects. If the value of GLOBAL_NAMES is FALSE, then no check is performed. Oracle recommends setting this parameter to TRUE to ensure the use of consistent naming conventions for databases and links.
If you have GLOBAL_NAMES set to TRUE and you create a database link A for database B you will get the following error when you try to use the link:
ORA-02085 database link name connects to name
Cause: The database link attempted to connect to a database with a different name. The name of the database link must be the same name as the name of the database.
Action: Create a database link with the same name as the database to which it connects.
HTH. Finn
Dante <dnotari_at_my-dejanews.com> wrote in message
news:7h11kk$4li$1_at_nnrp1.deja.com...
> Sean,
> that is not true.
>
> The name of the DB Link will be resolved in the PUBLIC
> namespace and the DB will use the connect string
> specified in the USING clause or the one specified
> when using the connect string.
>
> GLOBAL NAMES affects only the way the hostnames are
> resolved withing SQL*Net.
>
> You can use as Link name any name you want.
>
> Regards
> Dante
> In article <37337AC1.8AE72AC0_at_xmission.com>,
> Sean McMurray <smcmurr_at_xmission.com> wrote:
> > >>In article <01be988d$9c893140$95884f8b_at_rac17217.hasler.ascom.ch>,
> > >> "Buergi Josef" <josef.buergi_at_ascom.ch> wrote:
> > >> Hello
> > >>
> > >> I have two servers (same Network, Unix, each runs ORACLE V7, SQLNet
V2) and
> > >> want to set up a DB-link.
> >
> > Dante wrote:
> >
> > > Josef,
> > > It is
> > > CREATE PUBLIC DATABASE LINK <link>
> > > <CONNECT TO <user> IDENTIFIED BY <password>>
> > > USING <connectstring>;
> > >
> > > But I assume you know that anyway ... do you have the
> > > TNSNAMES entries on the servers as well ?
> > >
> > > Don't forget ... the server has to resolve the TNS entry not
> > > the client !
> > >
> > > Regards
> > > Dante
> >
> > Also remember that the name of the DB link must match the name of the
database
> > being referenced. This can be affected by GLOBAL NAMES usage, etc. but
it's
> > important to take into account.
> >
> > >
> > > >
> > > > Server one is called OBELIX
> > > > ----------------------------------------
> > > >
> > > > part of tnsnames.ors:
> > > >
> > > > V734MTS=(description=
> > > > (address=
> > > > (community=tcpcom)
> > > > (protocol=tcp)
> > > > (host=obelix)
> > > > (port=1521)
> > > > )
> > > > (connect_data=
> > > > (sid=V734MTS)
> > > > )
> > > > )
> > > >
> > > > Server two is called IDEFIX
> > > > ---------------------------------------
> > > >
> > > > part of tnsnames.ors:
> > > >
> > > > V716MTS=(description=
> > > > (address=
> > > > (community=tcpcom)
> > > > (protocol=tcp)
> > > > (host=idefix)
> > > > (port=1521)
> > > > )
> > > > (connect_data=
> > > > (sid=V716MTS)
> > > > )
> > > > )
> > > >
> > > > Each DB is running properly. Ich can do sqlplus scott/tiger_at_v716mts
from
> > > > obelix or sqlplus scott/tiger_at_v734mts from idefix.
> > > >
> > > > But .....
> > > >
> > > > I tried more than two hours to make a db link, but it does not work.
> > > >
> > > > Can anybody please give me the CREATE PUBLIC DATABASE LINK command
? Any
> > > > help is
> > > > really welcome.
> > > >
> > > > Regards
> > > > josef
> > > >
> > > > josef.buergi_at_ascom.ch
> > > >
> > >
> > > -----------== Posted via Deja News, The Discussion Network
==----------
> > > http://www.dejanews.com/ Search, Read, Discuss, or Start Your
Own
> >
> >
>
> -----------== Posted via Deja News, The Discussion Network ==----------
> http://www.dejanews.com/ Search, Read, Discuss, or Start Your Own
Received on Sat May 08 1999 - 07:55:28 CDT
![]() |
![]() |