materialized view replication

Hello

We currently have this configuration in our environment:
Db1 < Master site >
DB2 < Mview site - Readonly >

We use the replication at the table level. Basically, a NEWSPAPER MVIEW will be created each table in db1 and fast refresh of the table is programmed in the mview site 21:00 daily.

Now, there is an additional requirement to set up a new site < DB3 > mview. DB1 or DB2 data must be replicated to DB3.

Judge of our current environment, can we configure the mview new site based on the < Exisiting mview site > DB2? Or can only replicate in DB1 < master > DB3?

Please advise.

Thank you

You can replicate the materialized view site (DB2) to another site (DB3). See the link below (for 9i, should be same on later versions) for more details.

http://docs.Oracle.com/CD/B10501_01/server.920/a96567/repmview.htm

Salman

Tags: Database

Similar Questions

  • Simple example to configure read-only (materialized view) replication

    Hello world

    Can someone provide me with simple example to configure read-only (materialized view) replication?

    Also we have to manually re-create all indexes of the replicated database?

    Thank you
    Ken

    See

    http://download.Oracle.com/docs/CD/B19306_01/server.102/b14226/repmview.htm#i34980

    A MV is separated from the source table. You don't have to 'recreate' index. You can create separate (or the same) index on the MV - don't forget a MV can be a join of tables 2 or more! (Do not create a Unique Index on the MV)

    Hemant K Collette

  • Difference between the table and Materialized View

    Is there an advantage outside automatic synchronization (founded refresh selected type) using Materialized View?

    I came across this question as table and MV both store values, and we can also update table using the code what is the need of MV? Why not create a table instead of MV with the same definition and same charly?

    I need some explanation to force someone to convince himself.

    Thank you

    http://docs.Oracle.com/CD/B19306_01/server.102/b14223/basicmv.htm

    Sections that highlight its strengths:

    1. materialized views for data warehouses

    2. materialized views for distributed computing

    Query, re - write, features as Materialized view log files that can be used for replication between databases, etc...

  • Materialized view

    Hi all

    10g and 11g

    I can create my 'clean' indexes for a base table of Materialized view?

    Is required for replication of materialized view?

    Can I replicate the MV database table itself?


    Thank you very much


    zxy

    Published by: yxes2013 on 24.3.2013 22:03

    yxes2013 wrote:
    Thank you :)

    You know, I'm scared to touch him because it might get damaged and will not run its query rewrite the update of the transaction.

    Stop making excuses. See: [url http://edstevensdba.wordpress.com/category/opinion/] create your own test system

  • Materialized view Site DB Migration

    Hi guys,.

    Need advice on the below:

    We currently have this configuration in our environment:
    Master DB1 site (HP - UX Itanium)
    Site of DB2 Mview (HP - UX Itanium)

    We use the replication at the table level.
    Basically a NEWSPAPER MVIEW will be created for each table in the DB1 and fast table refresh is scheduled in DB2 MVIEW SITE daily between 02:00 and 05:00.

    We have a requirement to migrate the site mview DB2 for HP - UX to Solaris. (version of db remains)
    The size of the database is about 500 GB.

    1. can I use the cold backup in HP - UX Itanium, and restoration to the Solaris? Is it supported?
    2. our database is 500 GB which is pretty huge. So cold backup and restore method cannot be used, is recommended for a such enormous data base exp and imp? It will take quite long I think.
    3. everyday mview fast replication is scheduled between 02:00 and 05:00. If we were to use the exp and imp for the
    migration of the mView, the mview site will still work after importing? Complications? For example, after importing, the mview still will know where to continue to replicate based on the log of snapshot in the master probably due to the id of the row changed in mview site?
    4. any recommendation to perform the above task? DB version is 10.2.0.5

    Thank you!

    Hello

    My case is abit different as it is a site of mview.

    Transportable tablespace will transport mviews as well?

    This MOS score could be interesting in this case:

    * How to manage materialized views when you upgrade or clone a database [ID 1406586.1] *.

    But beware, this procedure has not been tested for all the version of Oracle.

    You must test it before on an environment of 'test '.

    Hope this helps.
    Best regards
    Jean Valentine

  • Bug: Cannot create materialized view log on XE 11 G

    Hello

    I connect as try and HR user create materialized view log
    CREATE MATERIALIZED VIEW LOG ON HR.EMPLOYEES;
    I get the error
    >
    Error from the 1 in the command line:
    CREATE LOG VIEW MATERIALIZED ON HUMAN RESOURCES. EMPLOYEES
    Error in the command line: 1 column: 0
    Error report:
    SQL error: ORA-00439: feature not enabled not: Advanced replication
    00439 00000 - "function not enabled: %s."
    * Cause: The specified feature is not enabled.
    * Action: Try not to use this feature.
    >

    You can create a materialized view log on 10G XE with no problems.

    Kind regards
    Jari

    http://dbswh.webhop.NET/dbswh/f?p=blog:Home:0

    Is this a bug in 11g or 10g?

    It was reported earlier in the beta forum now archived. {: identifier of the thread = 2214092}

    The current doc lists the MV sites only (and 'No' to the function of replication advanced):
    http://download.Oracle.com/docs/CD/E17781_01/license.112/e18068/TOC.htm#BABDFDAI

  • Materialized views or water courses

    I'm working on 11 GR 2 on Red Hat Linux

    I have a TBL_ADDRESS table on the DB1 database and it is an OLTP database
    SQL> desc TBL_ADDRESS
    Name                                      Null?    Type
    ----------------------------------------- -------- --------------------

    CODE_ID                                   NOT NULL NUMBER(19)
    ADDRESS_LINE_1                            NOT NULL VARCHAR2(100)
    ADDRESS_LINE_2                            NOT NULL VARCHAR2(100)
    CITY                                      NOT NULL VARCHAR2(40)
    COUNTRY                                   NOT NULL VARCHAR2(40)
    I'm working on a data warehouse that needs these details, and also must capture changes (Dimension to slow variation).
    So I'm looking at a similar to that on the DB2(Data Warehouse) database table design
    SQL> desc TBL_ADDRESS_HISTORY
    Name                                      Null?    Type
    ----------------------------------------- -------- --------------------
    CODE_ID                                   NOT NULL NUMBER(19)
    ADDRESS_LINE_1                            NOT NULL VARCHAR2(100)
    ADDRESS_LINE_2                            NOT NULL VARCHAR2(100)
    CITY                                      NOT NULL VARCHAR2(40)
    COUNTRY                                   NOT NULL VARCHAR2(40)
    FROM_DATE                                 NOT NULL TIMESTAMP
    TO_DATE                                            TIMESTAMP
    The From_Date and To_Date fields will help me determine if the data is current and also it will help me to identify the changes that have occurred in the past.

    To get the data in the TBL_ADDRESS table in DB1, I have two options, configuration of the watercourse or using materialized views.

    (1) in the case of option 1, I have the same table (TBL_ADDRESS stream) on the DB2 database configured using the replication flow from DB1 to DB2. Then I can create triggers (on TBL_ADDRESS in DB2) in order to identify changes and have full accordingly TBL_ADDRESS_HISTORY table.

    (2) in the case of option 2, I have materialized view implemented using the links of db that will be refreshed every few hours. Also I will have TBL_ADDRESS in the populous initially DB2 table when DW is built. Until no refreshment of the MV, I'm having a procedure that checks the data in TBL_ADDRESS and the view materialized to see if there is no change and updates another table TBL_ADDRESS_HISTORY with the old data, if there is any change, so TBL_ADDRESS will have current data and TBL_ADDRESS_HISTORY will have the old data.

    It seems that Option 1 is better but I have about 8 tables (which have to be met to obtain the relevant data) so I thought having 8 process of watercourse would be a little complex to maintain.
    In the case of MV, I have 1 MV who joined all the tables of 8 and is updated twice a day.

    Any suggestions/advice?

    What do you mean by "8 workflow process? You would have a capture process, a propagation process, and a process applies that everything that happened to work with ADR of 8 different tables. Once you have configured streams, there is no increase in complexity to add additional tables in the replication process.

    If you use feeds, why would you use the triggers for copy of changes to the ADDRESS table in the ADDRESS_HISTORY table? If it's the process that you are considering, you would be better with a custom apply Manager who just applied the LCR ADDRESS from the source system to the ADDRESS_HISTORY table in the data warehouse. Of course, in a data warehouse, I would refrain usually the ADDRESS table are replicated in place and that a separate process ETL (is not a trigger) the processed data.

    Justin

  • Are materialized views in Oracle OLAP licenses. ?

    Hi all
    We use the EE Oracle 10 g 2. We try to find the list of products of Oracle 10gEE. License part materialized views in Oracle OLAP or that come with the Standard edition.

    Thank you

    Commerce 10.2 has a table of availability of the editing features (a SE, SE, EE) which establishes good enough differences:
    http://download.Oracle.com/docs/CD/B19306_01/license.102/b14199/editions.htm#BABJICBB

    However I don't see, documentation, its use of MV (license) is clearly defined. Basically, it seems it depends of the use of MVs.

    See, for example, Data Warehouse (syntheses) and integration - based replication. Sometimes, the documentation uses the phrase "materialized views to...» ». SQL aggregation / analytical seems to be a missing piece as well (in the current doc sets).
    http://download.Oracle.com/docs/CD/B19306_01/server.102/b14200/statements_6002.htm
    http://download.Oracle.com/docs/CD/B19306_01/server.102/b14223/basicmv.htm#i1006193
    http://download.Oracle.com/docs/CD/B19306_01/server.102/b14226/repmview.htm

    The new 11g Cube materialized views feature is of course an OLAP option.

    And, as usual, you can find in the documentation, forums etc is almost irrelevant when it comes to licensing issues. You should see your specific contract. Talk to your sales person.

    "License issues really, really, really should be addressed to your representative commercial Oracle." Nothing we say here links to Oracle. We don't know other agreements, your organization may have with Oracle. ... explaining that "a guy on the internet with a card to play said logo is OK," probably won't do more good. »
    (borrowed from Oracle licenses VMware + Quadcore

    Published by: orafad on January 27, 2011 20:39

  • Prob of materialized view

    Hi all


    I have problem with Mview when you perform dml operations.

    I'm trying to insert or update on the materialized view, then I am getting below error.

    ORA-01732: operation non-legal data manipulation on this point of view

    Please can you me cant we do on the materialized view dml operations?

    My version of DB is 10g.
    DESC SUNITHA;
    
    Name     Null?     Type
    NAME          VARCHAR2(10)
    ID     NOT NULL     NUMBER(2)
    create  MATERIALIZED  view maview as select * from sunitha;
    I'm trying to insert into maview
    insert into maview values('c',4);
    
    ORA-01732: data manipulation operation not legal on this view
    Please notify.


    Thank you
    Miriam.

    Here is an excerpt of the document.

    Updatable Materialized Views
    
    You can make a materialized view updatable during creation by including the FOR UPDATE
    clause or enabling the equivalent option in the Replication Management tool. For changes
    made to an updatable materialized view to be pushed back to the master during refresh,
    the updatable materialized view must belong to a materialized view group.
    
    Updatable materialized views enable you to decrease the load on master sites because users
    can make changes to the data at the materialized view site. The following is an example of
    an updatable materialized view:
    
    CREATE MATERIALIZED VIEW hr.departments FOR UPDATE AS
      SELECT * FROM [email protected];
    
    The following statement creates a materialized view group:
    
    BEGIN
       DBMS_REPCAT.CREATE_MVIEW_REPGROUP (
          gname => 'hr_repg',
          master => 'orc1.world',
          propagation_mode => 'ASYNCHRONOUS');
    END;
    /
    
    The following statement adds the hr.departments materialized view to the materialized
    view group, making the materialized view updatable:
    
    BEGIN
       DBMS_REPCAT.CREATE_MVIEW_REPOBJECT (
          gname => 'hr_repg',
          sname => 'hr',
          oname => 'departments',
          type => 'SNAPSHOT',
          min_communication => TRUE);
    END;
    
    /
    
    You can also use the Replication Management tool to create a materialized view group
    and add a materialized view to it.
    
  • Creation of privilege to write to the database master materialized view?

    I would like to create materialized views for a few tables of a production Oracle database replication. I have only read access to the source database. I think I need additional privileges to create the journal for the quick update. Is this correct? Have no option if I can't get additional privileges and cannot get a DBA to help me?

    If you need to fast refresh to materialized view log, you will need help of DBA.

    Otherwise, you need to create complete refresh Mviews.

  • Constraints foreign key in materialized views can be changed (approx 1-master)

    I have a system which consists of a master database and a bunch of materialized view sites homogeneous. 10.2.0.4 all around. Main server is Windows Server 2003. all remote nodes are Windows XP. All materialized views are editable. There are only 20 or two tables (materialized views). Users enter data in the system at the level of the remote nodes via an application.

    There are data integrity constraints in the database on the main site. In the hunt for replication errors, I discovered that the integrity constraints do not exist in the context of the remote node. Then, sometimes, that users can enter data not valid that main site integrity constraints disallow, producing errors of replication on the master site. For a test I then implemented manually some of the constraints on a remote node using the java Enterprise Manager UI. Constraints have behaved as expected, as far as I can tell.

    My ultimate goal is to implement, on all sites of the materialized view, the current constraints of the integrity of the main site, so that entering data at remote sites is governed by the integrity constraints.

    I looked briefly package DBMS_REPCAT subprograms. Nothing jumped out at me.

    I started to collect the DDL (ALTER TABLE... ADD CONSTRAINT...) I could run each site through SQL * more sheet calculation.

    Then I thought that maybe I could use sqldeveloper to run the DDL but when I open the relevant schema to the level of the remote nodes, the actual tables are not shown, only the USLOG$ _... things. Materialized views are shown - but they do not have a constraints tab.

    After some time in the manuals, I decided that I have a good knowledge of what I see; and that's why I'm not sure I'm running in the right direction.

    I will summarize two questions:

    (1) what is the best way for me to apply constraints of integrity of the master site existing in materialized views can be changed on all nodes?

    (2) why I can see and work on the tables on the remote nodes via the EM java, but don't can't see them via sqldeveloper, logged in with the same account twice?

    P.S. It is possible for me to delete and re-create all databases and the views materialized on all remote nodes. It is not a high volume system, and there are windows of time during which I can do these things if necessary. I don't expect a structural change to the database, so I don't need to be able to spread future changes, just make things sync'd up now.

    Published by: Clark October 10, 2008 11:38

    Hi Clark,.
    you are right THAT FK on mviews can cause many problems during refresh. I mentioned on delete cascade, but delete the null value or remove restricted can cause problem too. You cannot complete with active reftesh FK referencing MV PK.

    Because you cannot control the mviews refresh a refresh Group, that the problems I described before can occur.
    You have to my view of these possibilities:
    1 / move Ref. integrity check from the DB to the logic of the application
    2 / use triggers to maintain ref.integrity check DB
    3 / mutlimaster user instead of mviews replication

    But none of them have their more and less.
    1 / + FK is checked - take some time, any other manipulation of data through the application can break rules FK
    2 / + FK is cheked on DB level - you write triggers, lower performance, changing disorders tables
    3 / + FK is chedked at the DB level, - all the data is replicated on the table plan (for MV, you can define where cluase for replication mutlimaster not), with more than two masters, it is difficult to define the replication conflict resolition method that convert in the last time.

    Last post:
    I my case I use this "thing":
    Because our request has not been managed in environment 24 x 7 I wrote my own routine to refresh.
    This routine that follows:
    1 / disable necessary FK
    2 / call dbms_refresh.refresh to perform the refresh of the refresh Group
    3 / activate FK disabled in step 1 with the novalidate
    Refresh the jobs was launched at night.

  • ORA-12028: type of materialized view is not supported by the main site

    Hi guys!

    We face a problem these days about the materialized view.

    We have upgraded database version 9.2.0.7 directly to 10.2.0.5 (RHEL4 x 86) on the same host. Database uses the driver dg4odbc to connect with remote SQL Server 2012 through data binding called MIKSERI. Our developer team would like to have replicated SQL server table data side Oracle using the materialized view.

    They created Materialized view, but it is not at all to refresh the data. I tried to study a little bit, and whenever I try to change the view anyway I hit error:

    ORA-12028: view type is not supported by the master site materialized @ 'MIKSERI '.

    ORA-06512: at line 22

    I looked at the solutions proposed and discovered that it is maybe the compatible database parameter, so I changed from previous 9.2.0.0.0 to 10.2.0.1.0 but still no luck. Just to emphasize this database is of course different clone of production to a different database, with db name retained and other parameters, but on another host computer and listening port. I even try to change global name, but still no luck.

    Main problem is that refresh the work does not at all. To be more precise, we have created MV on the side of the Oracle and FULL Refresh should be done every 3 minutes. MV uses HS db link to the sql server database.

    During the creation of MV, we can see currently given to sql server, but the problem is that we cannot do MV to refresh every 3 minutes. When I try to change MV and put the refresh interval I get above error.

    Any kind of help would be greatly appreciated,

    Thank you

    I found the reason why my MV update jobs failed, job_queue_processes parameter was equal to 0. I change this setting and now works fine.

    Thank you for your time!

  • What is the best way to change a column type in the materialized view?

    Hello my dear friends,.

    I want to change a column type in a materialized view. VARCHAR2 NUMBER, so what do you recommend? What is the best way to do it?

    Thank you

    You can not change the data type of the column while there are data in the MV, so you might as well give up and recreate the MV with a TO_CHAR() around the column in question in the application of MV to get the data exactly as you want (be sure to include an appropriate format mask). That said, I'm fighting to think reasonable grounds to make such a change.

  • A drop materialized view error

    I tried to drop two materialized views (I want to drop one and the other as a test to make sure that the behavior was consistent) with SQL Developer today, using the GUI, not the window of SQL command. When I did this, Developer SQL with these MVs among the tables, he tried to run a 'DROP TABLE' rather than a 'DROP MATERIALIZED VIEW' statement and an ugly error message came up with that and of course she didn't. Is this a bug that needs to be addressed? Or maybe that it is already identified and addressed in a future version?

    Earl

    Looks like you're down the underlying table, not the materialized view.   If you have a my_mv of materialized view, there is also a table called my_mv.

    You must drop the materialized since the Materialized View node in Object Explorer view.

  • Materialized views Refresh method and refresh option

    Hi Experts,

    According to the docs, If the MV contains the following, MV is considered complex. I wonder is there any view data dictionary that indicates the type of MV? Because is very easy to the candidate a complex type mv. Because many queries contains the properties below.

    http://docs.Oracle.com/CD/B28359_01/server.111/b28326/repmview.htm#i52501

    http://docs.Oracle.com/CD/B28359_01/server.111/b28313/basicmv.htm

    Specifically, a materialized view is considered complex if the materialized view definition query contains:

    • A CONNECT BY clause
    • An INTERSECT , MINUS , or UNION ALL operation
    • he DISTINCT or UNIQUE keyword
    • In some cases, an aggregate function, although it is possible to have an aggregation function in the query definition and always have a simple materialized view
    • In some cases, joins other than those in a subquery, although it is possible to have joins in the definition to interrogate and still have a simple materialized view
    • In some cases, a UNION operation


    After that I kept going to read that I learned that when a VM is created, the refresh mode is specified according to the type of the MV. That means, using ON-DEMAND refresh mode is widespread. The documentation mentions that there isa also refresh option. My question is, is it possible to specify

    ON REQUEST and FAST together?

    Also, what are the differences between FULL and FAST. Ends truncate the table and fill it up again?

    ON COMMIT

    Refresh product automatically when a transaction which changed one of the paintings of the materialized view's retail is committed. This can be specified as the materialized view is quickly updatable (in other words, not complex). The ON COMMIT privilege is required to use this mode.

    ON DEMAND

    Refresh occurs when a user manually executes one of the procedures available refresh contained in the DBMS_MVIEW package ( REFRESH , REFRESH_ALL_MVIEWS , REFRESH_DEPENDENT ).

    COMPLETE

    Refreshes and recalculating the materialized view query definition.

    FAST

    Applies incremental changes to refresh the materialized view using the information recorded in the papers of the materialized view, or an SQL * Loader direct-path access or a partition maintenance operation.

    FORCE

    Applies FAST update if possible; otherwise, it applies COMPLETE Refresh.

    NEVER

    Indicates that the materialized view will not be updated with updating mechanisms.

    Select * from version of v$.

    Oracle Database 11 g Release 11.2.0.4.0 - 64 bit Production

    Thank you

    Çaglar wrote:

    ...

    Also, what are the differences between FULL and FAST. Ends truncate the table and fill it up again?

    ...

    Thank you

    I just want to answer the truncated question. Seems that nobody covered that yet.

    Answer: It depends.

    If you do a full refresh, then the default is to use ATOMIC_REFRESH = TRUE.

    This means that the update is done via an insert, delete , and ... Select.

    You can change it to ATOMIC_REFRESH = FALSE (parameter dbms_mview.refresh).

    This means that is a TRUNCATE and insert a ... Select with APPEND peak (path direct insert).

    Refresh if Atomic = FALSE is considerably faster than the default. Also way less Archives of newspapers are written.

    The downside is however that, during the update the MV is empty, is no longer an atomar operation!

    See also Oracle documentation: http://docs.oracle.com/cd/B28359_01/appdev.111/b28419/d_mview.htm#i997194

Maybe you are looking for