Determining Whether Global Naming Is Enforced 未解決?

gdutllf2006發表於2009-12-30

Determining Whether Global Naming Is Enforced

 

remote database

SQL> select global_name from global_name;

 

GLOBAL_NAME

--------------------------------------------------------------------------------

SALE.US.ORACLE.COM

 

 

Local database

 

SQL> show parameter global_names;

 

NAME                                 TYPE        VALUE

------------------------------------ ----------- ------------------------------

global_names                         boolean     FALSE

 

SQL> create public database link hq_sales CONNECT TO test IDENTIFIED BY test  USING 'sales'

 

 

SQL> SELECT  count(*) from test@hq_sales;

 

  COUNT(*)

----------

     28026

 

SQL> alter system set global_names=true ;

 

System altered.

 

SQL> create public database link hq_sales_true CONNECT TO test IDENTIFIED BY test  USING 'sales';

 

Database link created.

 

SQL> select count(*) from test@hq_sales_true;

select count(*) from test@hq_sales_true

                          *

ERROR at line 1:

ORA-02085: database link HQ_SALES_TRUE.US.ORACLE.COM connects to

SALE.US.ORACLE.COM

 

結論:測試證明,當local database Global_names=true時, Database link name必須與Remote database global_name的名稱一致

但與P895<>描述的完全不一致。是哪裡出問題了?理解有誤 ?

Determining Whether Global Naming Is Enforced

The name that you give to a link on the local database depends on whether the remote database that you want to access enforces global naming. If the remote database enforces global naming, then you must use the remote database’s global database name as the name of the link. For example, if you are connected to the local hq server and want to create a link to the remote mfg database, and mfg enforces global naming, then you must use mfg’s global database name as the link name.

 

來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/10248702/viewspace-624035/,如需轉載,請註明出處,否則將追究法律責任。

相關文章