oracle 建同义词语句,Oracle 同义词的创建

创建public dblink 。

createpublicdatabaselinktest_link

connecttocsservicedbidentifiedbyhuawei123

using'(DESCRIPTION=

(ADDRESS_LIST=

(ADDRESS=(PROTOCOL=TCP)(HOST=192.168.0.119)(PORT=1521))

)

(CONNECT_DATA=

(SERVICE_NAME=orcl)

)

)';

Databaselinkcreated.

sql>desccs_user;

ERROR:

ORA-04043:objectcs_userdoesnotexist

sql>desccs_user@test_link;

NameNull?Type

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

PK_BUR_USERIDNOTNULLVARCHAR2(18)

BUR_USER_FLAGNOTNULLVARCHAR2(32)

select*fromdba_objectswhereobject_type='DATABASELINK';

selectowner,db_linkfromdba_db_links;--查看dblink的owner及link名字

删除dblink 。

sql>DROPPUBLICDATABASELINKcsmain;

Databaselinkdropped.

你可能感兴趣的:(oracle,建同义词语句)