Collected posts: Oracle, SQL, PL/SQL, Performance, Security...(More than 300 blogs)

dimanche 29 novembre 2015

ORA-22992: cannot use LOB locators selected from remote tables

 

ORA-22992: cannot use LOB locators selected from remote tables

--- Remote DB
create table CHB_TEST 
(
 DATA CLOB  

);
--- LOCAL DB
select   DATA    from CHB_TEST@<ORACLE_DB_LINK_REMOTE_DB> 

ORA-22992: cannot use LOB locators selected from remote tables

 select dbms_lob.substr@<ORACLE_DB_LINK_REMOTE_DB>( DATA , 4000) from CHB_TEST@<ORACLE_DB_LINK_REMOTE_DB

dimanche 1 février 2015

How to get Oracle system change number (SCN) ?




The SYSTEM CHANGE NUMBER = A stamp that defines a committed version of a database at a point in time. Oracle assigns every committed transaction a unique SCN.
USER_A@MYDB 01022015 09:24:45> SELECT CURRENT_SCN FROM V$DATABASE;

CURRENT_SCN
-----------
    2544927


USER_A@MYDB 01022015 09:24:46> SELECT DBMS_FLASHBACK.GET_SYSTEM_CHANGE_NUMBER FROM DUAL;

GET_SYSTEM_CHANGE_NUMBER
------------------------
                 2544927


The User_A should have the privileges execute on DBMS_FLASHBACK and SELECT on V_$DATABASE