Discussion:
Database link cannot be dropped
(too old to reply)
Forte Agent
2006-07-13 01:50:07 UTC
Permalink
Dumb question . . . . .

I have an Oracle database 10.2.0.2 where I cannot drop database links.
When I do "drop database link XXX", database link named
"XXX.domainname.com" is dropped, but not "XXX". What should I do?
Thank you in advance.
gazzag
2006-07-13 09:45:02 UTC
Permalink
Post by Forte Agent
Dumb question . . . . .
I have an Oracle database 10.2.0.2 where I cannot drop database links.
When I do "drop database link XXX", database link named
"XXX.domainname.com" is dropped, but not "XXX". What should I do?
Thank you in advance.
What do you get from the following query?

SELECT * FROM DBA_DB_LINKS;

Additionally, post your sqlnet.ora file so we can see that.

HTH

-g
Mark D Powell
2006-07-13 13:54:23 UTC
Permalink
Post by gazzag
Post by Forte Agent
Dumb question . . . . .
I have an Oracle database 10.2.0.2 where I cannot drop database links.
When I do "drop database link XXX", database link named
"XXX.domainname.com" is dropped, but not "XXX". What should I do?
Thank you in advance.
What do you get from the following query?
SELECT * FROM DBA_DB_LINKS;
Additionally, post your sqlnet.ora file so we can see that.
HTH
Forte, the DDL you posted would drop a private database link owned by
the connected Oracle username. Who does the link you are trying to
drop belong to? The query gazzag posted will provide the necessary
information.

drop public database link xxx.whatever;

HTH -- Mark D Powell --
Forte Agent
2006-07-19 20:13:49 UTC
Permalink
Thank you all for help. My SQLNET.ORA has followings only:
NAMES.DIRECTORY_PATH=(TNSNAMES, ONAMES, HOSTNAME)
SQLNET.EXPIRE_TIME= 10



Output from DBA_DB_LINKS is below:
OWNER DB_LINK USERNAME HOST CREATED
------------------------ -------- ------- -------------------
USER1 TESTDB5.DOMAIN.COM USER1 testdb5 15-06-2006 10:58:02
USER1 TESTDB5 USER1 testdb5 25-05-2006 21:37:32
USER2 DBLINK1.DOMAIN.COM USER3 devdb1 15-06-2006 11:06:25
USER2 DBLINK1 USER3 proddb1 20-02-2002 09:05:39
Post by Mark D Powell
Post by gazzag
Post by Forte Agent
Dumb question . . . . .
I have an Oracle database 10.2.0.2 where I cannot drop database links.
When I do "drop database link XXX", database link named
"XXX.domainname.com" is dropped, but not "XXX". What should I do?
Thank you in advance.
What do you get from the following query?
SELECT * FROM DBA_DB_LINKS;
Additionally, post your sqlnet.ora file so we can see that.
HTH
Forte, the DDL you posted would drop a private database link owned by
the connected Oracle username. Who does the link you are trying to
drop belong to? The query gazzag posted will provide the necessary
information.
drop public database link xxx.whatever;
HTH -- Mark D Powell --
Anurag Varma
2006-07-20 21:29:25 UTC
Permalink
Post by Forte Agent
Dumb question . . . . .
I have an Oracle database 10.2.0.2 where I cannot drop database links.
When I do "drop database link XXX", database link named
"XXX.domainname.com" is dropped, but not "XXX". What should I do?
Thank you in advance.
You might have global_names = true and have a domain specified.

You might need to set global_names to false to accomplish what you
are doing (However, understand the replication repurcussions of doing
that).

Anurag
Brian Peasland
2006-07-20 22:19:12 UTC
Permalink
Post by Anurag Varma
Post by Forte Agent
Dumb question . . . . .
I have an Oracle database 10.2.0.2 where I cannot drop database links.
When I do "drop database link XXX", database link named
"XXX.domainname.com" is dropped, but not "XXX". What should I do?
Thank you in advance.
You might have global_names = true and have a domain specified.
You might need to set global_names to false to accomplish what you
are doing (However, understand the replication repurcussions of doing
that).
Anurag
It may be worth a try, but did you enclose the link name in double quotes?

DROP DATABASE LINK "XXX";

It might not work, but it's worth a shot...

Cheers,
Brian
--
===================================================================

Brian Peasland
***@nospam.peasland.net
http://www.peasland.net

Remove the "nospam." from the email address to email me.


"I can give it to you cheap, quick, and good.
Now pick two out of the three" - Unknown
Loading...