Home > Administration, ORA-XXX > ORA-02085: database link DB2PCTVUAT connects to PCTVUAT

ORA-02085: database link DB2PCTVUAT connects to PCTVUAT

I create a database link from a development db to uat db. Then I test the connection as below and got the error ORA-02085

SQL> create database link db2pctvuat connect to strmadmin identified by strmadmin using ‘pctvuat’;

Database link created.

SQL> select tname from tab@db2pctvuat
2  ;
select tname from tab@db2pctvuat
*
ERROR at line 1:
ORA-02085: database link DB2PCTVUAT connects to PCTVUAT

Once I see the initial parameter global_name=false, the connection test is OK

SQL> select tname from tab@db2pctvuat;

no rows selected

Then, found a Metalink article (DocID=1024124.6), it said that …

  – GLOBAL_NAMES is set to TRUE, the name of the database link should match the global name of the target database
 –  GLOBAL_NAMES is set to FALSE, you can name the dblink anything you desire.

Since my uat database name is pctvuat, I test the database with global_names is set to true

SQL>  create database link pctvuat  connect to strmadmin identified by strmadmin using ‘pctvuat’;

Database link created.

SQL> select tname from tab@pctvuat;

no rows selected

SQL> drop database link DB2PCTVUAT;

Database link dropped.

SQL> show parameter global

NAME                                 TYPE        VALUE
———————————— ———– ——————————
global_context_pool_size             string
global_names                         boolean     TRUE

Advertisements
Categories: Administration, ORA-XXX
  1. No comments yet.
  1. No trackbacks yet.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: