Oracle 流stream数据的复制
--实验的目的是捕获scott.emp1表的变化,将变化应用到远程数据库scott.emp1表中。
--设置初始化参数
AQ_TM_PROCESSES=1
COMPATIBLE=9.2.0
LOG_PARALLELISM=1
GLOBAL_NAMES=true
JOB_QUEUE_PROCESSES=2
--查看数据库的名称,我的为ora9,将以下的ora9全部替换为你的数据库名称
--数据库为归档模式
conn scott/tiger
drop table emp1;
create table emp1 as select * from emp;
alter table emp1 add constraint pk_emp1 primary key (empno);
--建立管理用户,设定默认表空间,授权
conn / as sysdba
create tablespace streamout datafile 'F:\ORACLE\ORADATA\ORA9\streamout.dbf' size 20m
autoextend on;
create tablespace streamin datafile 'F:\ORACLE\ORADATA\ORA9\streamin.dbf' size 20m
autoextend on;
c