Re: Snapshot Materialized view : how to ?

From: Mohammad Aamir <mohammad.aamir_at_patni.com>
Date: 23 Jan 2004 02:48:32 -0800
Message-ID: <46eef817.0401230248.4e36d126_at_posting.google.com>


bsegonnes_at_free.fr (Bernard Segonnes) wrote in message news:<cc913d8.0401220618.3a2d50c4_at_posting.google.com>...
> Hi
>
> I'm a bit lost with snapshot creation, so can I have an easy (but with
> all details : *.ora, user grants, *.sql, db links, ...) example of
> snapshot between :
>
> Server1 :
> instance : I1
> oracle user : user1
> table : user1.table1
>
> Server2 :
> instance : I2
> oracle user : user2
> snapshot : user2.table1 as select * from user1.table1;
>
> Thank you for your examples.
>
> Bernard
> bsegonnes_at_free.fr
> http://bsegonnes.free.fr

Hi,

    Please do the following.

Locate Server1 and get the Tnsnames entry from the Tnsnames.ora file.

Paste this entry in the Tnsnames.ora file of the server2.

I am assuming that you are trying to connect to server1 from server2.

Please find out the schema name and password for User1.

assuming userid= user1 and password =password. Please query the following against the database on sever1. Global Database Name would be the output from Select * from global_name.
Service Name would be the output from Select * from v$database.

Assuming that the above queries fetched me the following results.

Global Database Name = sap.patni.com
Service Name = sap

You should have a create database link priviledge to create the link. Please ask your DBA to provide it to you.

Please run the following to create the link.

create database link sap.patni.com
connect to user1 identified by password
using 'sap';

I think creating a snapshot is easier than making it work through a database link. :-)

Aamir Received on Fri Jan 23 2004 - 11:48:32 CET

Original text of this message