Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.tools -> Re: Database link problem
In article <3ACC8E9C.243E96A3_at_grenoble.cemagref.fr>, Burnet Roland
<roland.burnet_at_grenoble.cemagref.fr> writes:
>xmark.powell_at_eds.com.x wrote:
>>
>> In article <3ACB3880.18389256_at_grenoble.cemagref.fr>, Burnet Roland
>> <roland.burnet_at_grenoble.cemagref.fr> writes:
>> >but not the same as Pierre HIRTH's last post.
>> >First excuse me for my bad English language
>> >Always two data bases :
>> >The first one on Oracle 8.0.5 SID = ORCL and hosted by
>> >machine1.my_domain
>> >The second one on Oracle 8.1.7 service name = trieves hosted by
>> >machine2.my_domain
>> >
>> >With SQLPlus I am connected to the second one with user2/pass2_at_trieves
>> >
>> >SQL> create database link orcl connect to user1 identified by pass1
>> > 2 using 'orcl';
>> >
>> >Lien de base de données créé. (Database link created)
>> >
>> >SQL> select * from departement_at_orcl;
>> >select * from departement_at_orcl
>> > *
>> >ERREUR à la ligne 1 : (Error at line 1 :)
>> >ORA-02085: lien de base de données ORCL.US.ORACLE.COM se connecte à
>> >ORCL.WORLD
>> > (database link ORCL.US.ORACLE.COM is connecting to
>> >ORCL.WORLD)
>> >
>> >Whereas in the same SQLplus windows
>> >
>> >SQL> connect user1/pass1_at_orcl;
>> >
>> >Connecté. (connected)
>> >SQL> select * from departement where num_dpt=4;
>> >
>> > NUM_DPT NOM_DPT
>> >---------- ----------------------------------------
>> > 4 Hautes Alpes
>> >
>> >Same problem, if the database link is created public
>> >The DB_DOMAIN parameter is set to my_domain.
>> >world is the value of NAME.DEFAULT_ZONE in sqlnet.ora file
>> >
>> >Could someone tell me why the database link tries a connection to
>> >US.ORACLE.COM when this string is not in the Oracle parameters and it is
>> >possible to connect to orcl ? (Obviously Tnsnames.ora seems right)
>> >
>> >Thanks in advance.
>> >
>> >R. Burnet.
>>
>> I do not know the exact answer to your question, but I do know how I fixed
>> basically the same error in my 8.1.7 test db. Add the domain name,
>> my_domain, to the Net 8 alias in the database link, orcl.my_domain, and
the
>> tnsnames.ora entrty should also include the domain name. This should
>> eliminate the error.
>>
>> -- Mark D. Powell --
>>
>> ----- Posted via NewsOne.Net: Free (anonymous) Usenet News via the Web
I just tested a link from an 8.1.7 database to an 8.0.5.2 on the same machine and to an 8.5.2.1 on a remote machine and they work fine. I have also tested a link running from 8.0.5 to 8.1.7 and it worked so maybe you should delete all the objects involved and recreate them. In the process perhaps you will fix whatever is wrong. If it still is wrong you will either need to post all the related code for another set of eyes to spot the problem or it could be time to talk to support. Good luck.
![]() |
![]() |