RE: infoworld call

  • From: "Allen, Brandon" <Brandon.Allen@xxxxxxxxxxx>
  • To: "ChrisDavid.Taylor@xxxxxxxxxxxxxxx" <ChrisDavid.Taylor@xxxxxxxxxxxxxxx>, "'oracle-l@xxxxxxxxxxxxx'" <oracle-l@xxxxxxxxxxxxx>
  • Date: Fri, 20 Jan 2012 19:01:00 +0000

Yes, test case and doc reference below:

http://docs.oracle.com/cd/B19306_01/server.102/b14200/statements_5005.htm:

"To create a private database link, you must have the CREATE DATABASE LINK 
system privilege. To create a public database link, you must have the CREATE 
PUBLIC DATABASE LINK system privilege. Also, you must have the CREATE SESSION 
system privilege on the remote Oracle database."


##### TEST03 DATABASE ######

SYS@test03>create user db_link_test identified by temporary112233;

User created.

SYS@test03>grant create session to db_link_test;

Grant succeeded.



##### DEMO DATABASE ######

SYS@demo>create user db_link_test identified by temporary112233;

User created.

SYS@demo>grant create session to db_link_test;

Grant succeeded.

SYS@demo>conn db_link_test
Enter password:
Connected.

DB_LINK_TEST@demo>create database link db_link_test connect to db_link_test 
identified by temporary112233 using 'test03';
create database link db_link_test connect to db_link_test identified by 
temporary112233 using 'test03'
                     *
ERROR at line 1:
ORA-01031: insufficient privileges

DB_LINK_TEST@demo>conn / as sysdba
Connected.

SYS@demo>grant create database link to db_link_test;

Grant succeeded.

@>conn db_link_test/temporary112233
Connected.

DB_LINK_TEST@demo>conn / as sysdba
Connected.

SYS@demo>select dbms_flashback.get_system_change_number from dual;

GET_SYSTEM_CHANGE_NUMBER
------------------------
               869661524

SYS@demo>conn db_link_test/temporary112233
Connected.

DB_LINK_TEST@demo>create database link db_link_test connect to db_link_test 
identified by temporary112233 using 'test03';

Database link created.



##### TEST03 DATABASE ######

SYS@test03>select dbms_flashback.get_system_change_number from dual;

GET_SYSTEM_CHANGE_NUMBER
------------------------
               721203624



##### DEMO DATABASE ######

DB_LINK_TEST@demo>select count(*) from user_tables@db_link_test;

  COUNT(*)
----------
         0



##### TEST03 DATABASE ######

SYS@test03>/

GET_SYSTEM_CHANGE_NUMBER
------------------------
               869661584




-----Original Message-----
From: oracle-l-bounce@xxxxxxxxxxxxx [mailto:oracle-l-bounce@xxxxxxxxxxxxx] On 
Behalf Of Taylor, Chris David

Right.  Any user that has create session privilege can have a db link created 
to it, right?


________________________________

Privileged/Confidential Information may be contained in this message or 
attachments hereto. Please advise immediately if you or your employer do not 
consent to Internet email for messages of this kind. Opinions, conclusions and 
other information in this message that do not relate to the official business 
of this company shall be understood as neither given nor endorsed by it.
--
//www.freelists.org/webpage/oracle-l


Other related posts: