Q
Problem solve Get help with specific problems with your technologies, process and projects.

ORA-02085 after connecting two schemas

I have two different schemas in the same database. One schema is LIVEDATA, the other schema is TESTDATA. I created a db link. Then I connected the TESTDATA schema, and then tried a query. I got the error ORA-02085.

I have two different schemas in the same database. One schema is LIVEDATA, the other schema is TESTDATA. I created a db link:
CREATE PUBLIC DATABASE LINK OLD_LINK CONNECT TO LIVEDATA IDENTIFIED BY LIVEDATA 
USING LIFE.STARCORP.LOCAL';
Then I connected the TESTDATA schema, and then tried the following query:
sql>SELECT * FROM DUAL@OLD_LINK;
I got the following:
ERROR at line 1:
ORA-02085: database link OLD_LINK.STARCORP.LOCAL connects to LIFE.STARCORP.LOCAL
Please help me. Thanks in advance.
The ORA-2085 error is raised because two conditions are true:
  1. The GLOBAL_NAMES initialization parameter is set to TRUE.
  2. The database name of the remote database does not match the database link name.
Either use a database link with the same name as the database name (LIFE.STARCORP.LOCAL) or set GLOBAL_NAMES to FALSE.

Dig Deeper on Oracle database design and architecture

Have a question for an expert?

Please add a title for your question

Get answers from a TechTarget expert on whatever's puzzling you.

You will be able to add details on the next page.

Start the conversation

Send me notifications when other members comment.

Please create a username to comment.

-ADS BY GOOGLE

SearchDataManagement

SearchBusinessAnalytics

SearchSAP

SearchSQLServer

TheServerSide.com

SearchDataCenter

SearchContentManagement

SearchHRSoftware

Close