• 234
    0

    What is Oracle real time backup system? Oracle streams replication is the process which enables Oracle database schema to replicate to another Oracle database. Which can be located to any location. Whenever a transaction occurs in the primary database DML or DDL it will execute immediately to the target database to maintain a live backup ...
  • 65
    0

    Creating DDL Trigger in Oracle to exclude tables to be captured which are not supported by Oracle Streams. Create this trigger in Oracle Stream Admin user and modify the owner with your schema name. This trigger fire whenever a table created in database and if table is containing unsupported data types then it will automatically ...
  • 49
    0

    Deleting existing rule sets after removing Oracle Streams Configuration  DECLARE  CURSOR VIN Is     Select RULESET_NAME From DBA_RULESETS Where OWNER = ‘STRMADMIN’;      BEGIN  For I In VIN LOOP     BEGIN  DBMS_RULE_ADM.DROP_RULE_SET(    rule_set_name => ‘STRMADMIN.’||I.RULESET_NAME,     delete_rules  => TRUE);  EXCEPTION    WHEN OTHERS THEN      NULL;  END;  END LOOP;    END;/
  • 93
    0

    After capture process creation edit and run below PLSQL block to ignore tables to be captured which are unsupported. DECLARE CURSOR VIN Is    Select TABLE_NAME     From DBA_STREAMS_UNSUPPORTED    Where OWNER = ‘URSCHEMA’;BEGIN   For C In VIN LOOP dbms_streams_adm.add_table_rules ( table_name => ‘URSCHEMA.’||C.TABLE_NAME, streams_type => ‘capture’, streams_name => ‘STREAMS_CAPTURE’, queue_name => ‘STRMADMIN.STREAMS_CAPTURE_Q’, include_dml => true, include_ddl => false, inclusion_rule => false, source_database => ‘STREAM’ );END LOOP;COMMIT;
  • 67
    0

    Below is the example handle duplicate rows in Oracle Streams. BEGIN  DBMS_APPLY_ADM.SET_PARAMETER(    apply_name  => ‘STREAMS_APPLY’,     parameter   => ‘allow_duplicate_rows’,     value       => ‘Y’);END;/
  • 67
    0

    Run this script in stream admin user at target database, to prevent drop for the tables. Example conn [email protected] create or replace procedure IGNORE_DROP_TABLE (in_any IN SYS.ANYDATA )  is lcr SYS.LCR$_DDL_RECORD; rc PLS_INTEGER;  begin rc := in_any.GETOBJECT(lcr);  if lcr.GET_COMMAND_TYPE != ‘DROP TABLE’ then     lcr.execute(); end if; END; /  begin dbms_apply_adm.alter_apply( apply_name => ‘STREAMS_APPLY’, ddl_handler => ‘IGNORE_DROP_TABLE’); end; /