Creating Snapshot
Snapshot
Snapshot replicating tables on remote locations.
E.g. In Rawalpindi on DBSVR create Snapshot for remote
account table in KARACHI.
Snapshot is created same as we create VIEW of a table, but the
difference is that any DML operation on BASE table will not
effect snapshot.
It is useful when we are not changing data in the base table.
Creating Snapshot
SQL> create snapshot emp_copy as select * from emp;
emp;
Snapshot created.
SQL> select * from tab;
TNAME
-----------------------------BONUS
DEPT
EMP
EMP_COPY
SALGRADE
SNAP$_EMP_COPY
TABTYPE CLUSTERID
------- --------TABLE
TABLE
TABLE
VIEW
TABLE
TABLE
SQL> delete from emp;
emp;
SQL> insert into emp(empno,
emp(empno, deptno)
deptno) values(1254,10);
1 row created.
SQL> select * from emp_copy;
emp_copy;
Q
&
A
[email protected]