Oracle Reports 6i w/ Materialized Views

Is Oracle Reports 6i integrated with Materialized Views? If so, is there a patch out there so the query builder will see them? The query is fine in Sql+ but Reports doesn't recognize the materialized views. What is the fix?

hello,
when you paste the query into the sql-window it should work. only the query-builder-tool does not pick them up.
regards,
the oracle reports team

Similar Messages

  • Oracle Text Index on Materialized View

    Hello,
    I have designed a search engine for an internet application.
    We have different tables for our main business objects, the search is based on the content of all these dependent entities (Product, Company etc...)
    So I have created a materialized view to embody this aggregation.
    Then I have created a Multi column datastore index on top of the snapshot.
    The search engine has to be refreshed automatically 3 times a day, and manually anytime.
    This is achieved by executing a complete refresh on the view and rebuild the index, programmatically via Toplink (SqlCall).
    The MV refresh looks like this :
    alter index usr_batiprod.fullTextMulticolIdx rebuild
    and the index rebuild:
    begin
    DBMS_MVIEW.REFRESH('FT_TEST','C');
    end;
    Everything was fine until now, we have had lots of tuning on the index side, the refresh process was working fine...
    We have let the users access the engine since Thursday (the index had been created on the production environment a fews weeks ago) and since yesterday (or maybe before) we have been experiencing data incoherency on the index...
    I've tracked down the pb to the Fulltext Search's refresh process (manual and automatic share the same code) that was crashing on the Materialized view refresh :
    java.sql.SQLException: ORA-20000: Oracle Text error:
    DRG-50610: internal error: drexdsync
    DRG-50857: oracle error in drekrtd (lob erase)
    ORA-00060: deadlock detected while waiting for resource
    ORA-06512: at "SYS.DBMS_SNAPSHOT", line 794
    ORA-06512: at "SYS.DBMS_SNAPSHOT", line 851
    ORA-06512: at "SYS.DBMS_SNAPSHOT", line 832
    ORA-06512: at line 2
    Again, we had tested the functionality thoroughly and never experienced such behaviour before... even while refreshing the materialized view and the index 3 times (or more) a day..
    Once I dropped the Oracle Text Index, I was able to refresh the MV again..
    so it looks like the index was in some incoherent state and was holding a lock on the materialized view...
    Maybe my Index refresh call is wrong, and a stronger load on the functionality leads quickly to this pb, I dont know..
    I had always been a bit doubtful towards my index rebuild call, so Im thinking about using a more complete call :
    alter index usr_batiprod.fullTextMulticolIdx rebuild parameters ('sync')
    is it enough, or do I have to switch to a 'Oracle Text' specific call ?
    Is there another possible reason for the MV lock ?
    Thank you for your support
    Best Regards
    Olivier Cuzacq

    MVs are constructed in different ways and have lots of different uses.
    Why not just use MV as temp table for OT (Oracle Text) index?
    Refresh MV OT_TEMP.
    Delete all not matching rows from OT.
    Insert all missing missing rows from OT_TEMP to OT.
    sync OT index (online).
    Query table OT.

  • Can Oracle materialized view be used as crystal report datasource

    Hi,
    Can we use materialized view created in Orace 10g database as the data source of crystal reports.
    I'm using Crystal reports Server 2008 V1 version. I'm unable to find the materialized view under my data connection. I can see only tables, static views and stored procedures.
    Is there a way by which I can run my reports against a materialized view created in Oracle.
    Thanks
    Thomas EL

    Hi Thomas,
    Rather than doing all of this work around to access multiple databases/servers why not create a stored procedure to do all of this for you? Search the notes area for samples on how/what CR requires to use a SP in Oracle.
    Advantages is this is done all server side and CR simply waits for the data to be returned. Even if you are using a BVM or connecting directly to the SP, both cases are server side. Database servers are much more efficient and optimized to run queries and filtering data. CR has to do the filtering on it's second pass and that causes performance delays.
    Thank you
    Don

  • Materialized view fast refresh error

    hi,
    I have a materialized view created with fast refresh on demand option. Now when i try to refresh it manually the next day, it gives me an error . I have both count(*) and count(1) inside the materialized view. There is update and delete transactions done on most of the tables. The refresh is set to be at 4 am though a refresh group . But it fails with the error shown below . Please help. thanks
    here is the script from toad
    DROP MATERIALIZED VIEW MYPORTAL.ACCOUNT_COST_CATEGORY_MV;
    CREATE MATERIALIZED VIEW MYPORTAL.ACCOUNT_COST_CATEGORY_MV
    TABLESPACE USERS
    PCTUSED    0
    PCTFREE    10
    INITRANS   2
    MAXTRANS   255
    STORAGE    (
                INITIAL          64K
                MINEXTENTS       1
                MAXEXTENTS       UNLIMITED
                PCTINCREASE      0
                BUFFER_POOL      DEFAULT
    NOCACHE
    LOGGING
    NOCOMPRESS
    NOPARALLEL
    BUILD IMMEDIATE
    USING INDEX
                TABLESPACE USERS
                PCTFREE    10
                INITRANS   2
                MAXTRANS   255
                STORAGE    (
                            INITIAL          64K
                            MINEXTENTS       1
                            MAXEXTENTS       UNLIMITED
                            PCTINCREASE      0
                            BUFFER_POOL      DEFAULT
    REFRESH FAST ON DEMAND
    WITH PRIMARY KEY
    AS
    /* Formatted on 2011/01/07 10:04 (Formatter Plus v4.8.8) */
    SELECT   ac.account_id,
             ac.account_manager mgr_id,
             ac.account_number,
             ac.account_name,
             bc.burden_center_name burden_center,
             p.surname_isi || ', ' || p.first_name account_manager,
             p.division_id,
             item.code_id,
             item.code_name cost_category_item,
             TO_NUMBER (TO_CHAR (ap.first_day, 'YYYY')) period_year,
             ap.first_day period,
             ap.fiscal_system_period_cal_yr_eq || ', ' || ap.fiscal_year period_asr,
             COUNT (*) total_row_count,
             COUNT (1) total_one_count,
             SUM (NVL (ad.current_expense, 0)) expense,
             SUM (NVL (ad.total_budget, 0)) budget,
             SUM (NVL (ad.cumltv_expense, 0)) cumltv_expense,
             SUM (NVL (ad.commitments, 0)) commitments,
             SUM (NVL (ad.budget_balance, 0)) budget_balance
        FROM accounts ac,
             burden_centers bc,
             personnel p,
             asr_headers ah,
             asr_details ad,
             codes item,
             codes costcat,
             all_periods ap,
             codes cost_element,
             accounting_base_group abg
       WHERE ac.account_manager = p.personnel_id
         AND ac.burden_center_id = bc.burden_center_id
         AND ac.account_id = ah.account_id
         AND ah.asr_header_id = ad.asr_header_id
         AND ah.period_asr =
                       ap.fiscal_system_period_cal_yr_eq || ', ' || ap.fiscal_year
         AND abg.cost_element_cat_item_id = item.code_id
         AND cost_element.code_id = abg.cost_element_id
         AND ad.object_code = cost_element.code_value
         AND item.code_parent_id = costcat.code_id
         AND (   costcat.code_name = 'Report 1'
              OR (costcat.code_name = 'Base' AND item.code_name = 'MTDC')
    GROUP BY ac.account_id,
             ac.account_manager,
             ac.account_number,
             ac.account_name,
             bc.burden_center_name,
             p.surname_isi || ', ' || p.first_name,
             p.division_id,
             item.code_id,
             item.code_name,
             TO_NUMBER (TO_CHAR (ap.first_day, 'YYYY')),
             ap.first_day,
             ap.fiscal_system_period_cal_yr_eq || ', ' || ap.fiscal_year;
    COMMENT ON MATERIALIZED VIEW MYPORTAL.ACCOUNT_COST_CATEGORY_MV IS 'snapshot table for snapshot MYPORTAL.ACCOUNT_COST_CATEGORY_MV';
    CREATE INDEX MYPORTAL.ACCOUNT_COST_CAT_MV_IDX ON MYPORTAL.ACCOUNT_COST_CATEGORY_MV
    (ACCOUNT_ID, CODE_ID, PERIOD)
    LOGGING
    TABLESPACE USERS
    PCTFREE    10
    INITRANS   2
    MAXTRANS   255
    STORAGE    (
                INITIAL          64K
                MINEXTENTS       1
                MAXEXTENTS       UNLIMITED
                PCTINCREASE      0
                BUFFER_POOL      DEFAULT
    NOPARALLEL;
    -- Note: Index I_SNAP$_ACCOUNT_COST_CATEG will be created automatically
    --       by Oracle with the associated materialized view.
    here is the error :
    10:10:04 SQL>  exec dbms_mview.refresh('account_cost_category_mv');
    BEGIN dbms_mview.refresh('account_cost_category_mv'); END;
    ERROR at line 1:
    ORA-32314: REFRESH FAST of "MYPORTAL"."ACCOUNT_COST_CATEGORY_MV" unsupported after deletes/updates
    ORA-06512: at "SYS.DBMS_SNAPSHOT", line 2254
    ORA-06512: at "SYS.DBMS_SNAPSHOT", line 2460
    ORA-06512: at "SYS.DBMS_SNAPSHOT", line 2429
    ORA-06512: at line 1
    10:10:14 SQL>

    alright, i did a explain_mview, and then query the table , here is the result.
    exec DBMS_MVIEW.EXPLAIN_MVIEW('account_cost_category_mv');
    select   MVOWNER, MVNAME, CAPABILITY_NAME, POSSIBLE
    from     MV_CAPABILITIES_TABLE
    where  CAPABILITY_NAME = 'REFRESH_FAST' ;
    MVOWNER     MVNAME                    CAPABILITY_NAME     POSSIBLE   
    MYPORTAL    ACCOUNT_COST_CATEGORY_MV  REFRESH_FAST        Y           So why is it still giving the error ?

  • Materialized View with Joins

    Dear Dev/DBAs,
    I have the following scenario:
    SQL> CREATE TABLE T1 (ID NUMBER(3),NAME VARCHAR2(10));
    SQL> CREATE TABLE T2 (ID NUMBER(3),NAME VARCHAR2(10));
    The T1 contains records having the ID num from 10 to 80 and the T2 having the ID from 90 to 170
    SQL> SELECT * FROM T1 JOIN ALL SELECT * FROM T2
    It give all records in the 2 tables.
    I'm planning to create a materialized view (like CREATE MATERIALIZED VIEW V_TAB REFRESH ON COMMIT AS SELECT * FROM T1 JOIN ALL SELECT * FROM T2) and it seems i can't do with the error ORA-12054, further the oracle documentation says that materialized view can only be used with a simple join.
    Do you have another solution??
    Note that the materialized views can be used to improve queries.
    Thank you in advance

    Straight from the link I posted:
    *Restrictions on Fast Refresh on Materialized Views with UNION ALL*Materialized views with the UNION ALL set operator support the REFRESH FAST option if the following conditions are satisfied:
    * The defining query must have the UNION ALL operator at the top level.
    The UNION ALL operator cannot be embedded inside a subquery, with one exception: The UNION ALL can be in a subquery in the FROM clause provided the defining query is of the form SELECT * FROM (view or subquery with UNION ALL) as in the following example:
    CREATE VIEW view_with_unionall AS
    (SELECT c.rowid crid, c.cust_id, 2 umarker
    FROM customers c WHERE c.cust_last_name = 'Smith'
    UNION ALL
    SELECT c.rowid crid, c.cust_id, 3 umarker
    FROM customers c WHERE c.cust_last_name = 'Jones');
    CREATE MATERIALIZED VIEW unionall_inside_view_mv
    REFRESH FAST ON DEMAND AS
    SELECT * FROM view_with_unionall;
    Note that the view view_with_unionall satisfies the requirements for fast refresh.
    * Each query block in the UNION ALL query must satisfy the requirements of a fast refreshable materialized view with aggregates or a fast refreshable materialized view with joins.
    The appropriate materialized view logs must be created on the tables as required for the corresponding type of fast refreshable materialized view.
    Note that the Oracle Database also allows the special case of a single table materialized view with joins only provided the ROWID column has been included in the SELECT list and in the materialized view log. This is shown in the defining query of the view view_with_unionall.
    * The SELECT list of each query must include a maintenance column, called a UNION ALL marker. The UNION ALL column must have a distinct constant numeric or string value in each UNION ALL branch. Further, the marker column must appear in the same ordinal position in the SELECT list of each query block.
    * Some features such as outer joins, insert-only aggregate materialized view queries and remote tables are not supported for materialized views with UNION ALL.
    * Partiton Change Tracking (PCT)-based refresh is not supported for UNION ALL materialized views.
    * The compatibility initialization parameter must be set to 9.2.0 or higher to create a fast refreshable materialized view with UNION ALL.

  • Materialized view with dynamic filter

    I have a query which has a dynamic filter in the where clause. Dynamic in the sense, the value in the where condition will be obtained only when the query is run.
    The user interface is Business Objects tool i am using, based on the user login variable, the query is formed. Is there a possibilty to create a materialized view using this query.
    The query looks like this. The part in BOLD section is the filter. This query is taking long time and hence i am going for materialized view. Please suggest a solution
    SELECT
    DM_SALES.SALES_ORG_DIM.POSITION_LEVEL_5_DESC,
    SUM(case when PERIOD_DIM.FISCAL_PERIOD_NBR = ( DM_SALES.CURRENT_DATE_PERIOD_DIM.FISCAL_PERIOD_NBR ) and PERIOD_DIM.FISCAL_YEAR=( DM_SALES.CURRENT_DATE_PERIOD_DIM.FISCAL_YEAR ) then SALES_FACT.NET_SALES_USD else 0 end),
    SUM(case when PERIOD_DIM.FISCAL_PERIOD_NBR= ( DM_SALES.CURRENT_DATE_PERIOD_DIM.FISCAL_PERIOD_NBR ) and PERIOD_DIM.FISCAL_YEAR=( DM_SALES.CURRENT_DATE_PERIOD_DIM.FISCAL_YEAR )-1 AND PERIOD_DIM.FISCAL_DAY_IN_PERIOD BETWEEN 1 AND ( DM_SALES.CURRENT_DATE_PERIOD_DIM.FISCAL_DAY_IN_PERIOD ) then SALES_FACT.NET_SALES_USD else 0 end),
    SUM(case when
    PERIOD_DIM.FISCAL_YEAR=( DM_SALES.CURRENT_DATE_PERIOD_DIM.FISCAL_YEAR ) then SALES_FACT.NET_SALES_USD else 0 end),
    SUM(case when PERIOD_DIM.FISCAL_YEAR= ( DM_SALES.CURRENT_DATE_PERIOD_DIM.FISCAL_YEAR )-1
    AND PERIOD_DIM.FISCAL_DAY_IN_YEAR BETWEEN 1 AND ( DM_SALES.CURRENT_DATE_PERIOD_DIM.FISCAL_DAY_IN_YEAR )
    then SALES_FACT.NET_SALES_USD else 0 end),
    SUM(case when PERIOD_DIM.FISCAL_PERIOD_NBR = ( DM_SALES.CURRENT_DATE_PERIOD_DIM.FISCAL_PERIOD_NBR )and PERIOD_DIM.FISCAL_YEAR=( DM_SALES.CURRENT_DATE_PERIOD_DIM.FISCAL_YEAR ) then SALES_FACT.MUNITS_SOLD_QTY else 0 end),
    SUM(case when PERIOD_DIM.FISCAL_PERIOD_NBR= ( DM_SALES.CURRENT_DATE_PERIOD_DIM.FISCAL_PERIOD_NBR ) and PERIOD_DIM.FISCAL_YEAR=( DM_SALES.CURRENT_DATE_PERIOD_DIM.FISCAL_YEAR )-1 AND PERIOD_DIM.FISCAL_DAY_IN_PERIOD BETWEEN 1 AND ( DM_SALES.CURRENT_DATE_PERIOD_DIM.FISCAL_DAY_IN_PERIOD ) then SALES_FACT.MUNITS_SOLD_QTY else 0 end),
    SUM(case when
    PERIOD_DIM.FISCAL_YEAR=( DM_SALES.CURRENT_DATE_PERIOD_DIM.FISCAL_YEAR ) then SALES_FACT.MUNITS_SOLD_QTY
    else 0 end),
    SUM(case when PERIOD_DIM.FISCAL_YEAR= ( DM_SALES.CURRENT_DATE_PERIOD_DIM.FISCAL_YEAR )-1 AND PERIOD_DIM.FISCAL_DAY_IN_YEAR BETWEEN 1 AND ( DM_SALES.CURRENT_DATE_PERIOD_DIM.FISCAL_DAY_IN_YEAR )
    then SALES_FACT.MUNITS_SOLD_QTY else 0 end),
    SUM(case when PERIOD_DIM.FISCAL_PERIOD_NBR = ( DM_SALES.CURRENT_DATE_PERIOD_DIM.FISCAL_PERIOD_NBR ) and PERIOD_DIM.FISCAL_YEAR= ( DM_SALES.CURRENT_DATE_PERIOD_DIM.FISCAL_YEAR ) then
    SALES_FACT.CASES_SOLD_QTY else 0 end),
    SUM(case when PERIOD_DIM.FISCAL_PERIOD_NBR= ( DM_SALES.CURRENT_DATE_PERIOD_DIM.FISCAL_PERIOD_NBR )and PERIOD_DIM.FISCAL_YEAR=( DM_SALES.CURRENT_DATE_PERIOD_DIM.FISCAL_YEAR )-1 AND PERIOD_DIM.FISCAL_DAY_IN_PERIOD BETWEEN 1 AND ( DM_SALES.CURRENT_DATE_PERIOD_DIM.FISCAL_DAY_IN_PERIOD ) then SALES_FACT.CASES_SOLD_QTY else 0 end),
    SUM(case when
    PERIOD_DIM.FISCAL_YEAR=( DM_SALES.CURRENT_DATE_PERIOD_DIM.FISCAL_YEAR ) then SALES_FACT.CASES_SOLD_QTY
    else 0 end),
    SUM(case when PERIOD_DIM.FISCAL_YEAR= ( DM_SALES.CURRENT_DATE_PERIOD_DIM.FISCAL_YEAR )-1 AND PERIOD_DIM.FISCAL_DAY_IN_YEAR BETWEEN 1 AND ( DM_SALES.CURRENT_DATE_PERIOD_DIM.FISCAL_DAY_IN_YEAR )
    then SALES_FACT.CASES_SOLD_QTY else 0 end),
    DM_SALES.CURRENT_DATE_PERIOD_DIM.FISCAL_YEAR,
    DM_SALES.CURRENT_DATE_PERIOD_DIM.FISCAL_MONTH_NAME,
    DM_SALES.SALES_ORG_DIM.POSITION_LEVEL_6_DESC,
    DM_SALES.SALES_ORG_DIM.POSITION_LEVEL_7_DESC,
    DM_SALES.SALES_ORG_DIM.POSITION_LEVEL_8_DESC,
    CONCAT (CONCAT(SHIP_TO_CUST_DIM.SOURCE_CUST_NBR,'-'),SHIP_TO_CUST_DIM.SOLD_TO_CUST_NAME),
    CONCAT (CONCAT(SHIP_TO_CUST_DIM.SOURCE_CUST_NBR,'-'),SHIP_TO_CUST_DIM.SHIP_TO_CUST_LOC_NAME)
    FROM
    DM_SALES.SALES_ORG_DIM,
    PERIOD_DIM,
    SALES_FACT,
    DM_SALES.CURRENT_DATE_PERIOD_DIM,
    SHIP_TO_CUST_DIM
    WHERE
    ( SALES_FACT.INVOICE_DATE_KEY(+)=PERIOD_DIM.PERIOD_KEY )
    AND ( SHIP_TO_CUST_DIM.SHIP_TO_CUST_KEY=SALES_FACT.SHIP_TO_CUST_KEY )
    AND ( SALES_FACT.SALES_ORG_KEY=DM_SALES.SALES_ORG_DIM.SALES_ORG_KEY )
    AND ( PERIOD_DIM.PERIOD_KEY<=DM_SALES.CURRENT_DATE_PERIOD_DIM.PERIOD_KEY )
    AND
    ( DM_SALES.SALES_ORG_DIM.POSITION_LEVEL_5_DESC=(SELECT DM_SALES.SECURITY_HEADER.SALES_ORG_POSITION_DESC from DM_SALES.SECURITY_HEADER
    WHERE DM_SALES.SECURITY_HEADER.BOLOGIN = @VARIABLE('BOUSER')) ) AND
    ( PERIOD_DIM.FISCAL_YEAR>=DM_SALES.CURRENT_DATE_PERIOD_DIM.FISCAL_YEAR-1 )
    GROUP BY
    DM_SALES.SALES_ORG_DIM.POSITION_LEVEL_5_DESC,
    DM_SALES.CURRENT_DATE_PERIOD_DIM.FISCAL_YEAR,
    DM_SALES.CURRENT_DATE_PERIOD_DIM.FISCAL_MONTH_NAME,
    DM_SALES.SALES_ORG_DIM.POSITION_LEVEL_6_DESC,
    DM_SALES.SALES_ORG_DIM.POSITION_LEVEL_7_DESC,
    DM_SALES.SALES_ORG_DIM.POSITION_LEVEL_8_DESC,
    CONCAT (CONCAT(SHIP_TO_CUST_DIM.SOURCE_CUST_NBR,'-'),SHIP_TO_CUST_DIM.SOLD_TO_CUST_NAME),
    CONCAT (CONCAT(SHIP_TO_CUST_DIM.SOURCE_CUST_NBR,'-'),SHIP_TO_CUST_DIM.SHIP_TO_CUST_LOC_NAME)

    You could potentially create a single materialized view that had no restriction on the BOLOGIN column and allow Oracle to use that materialized view to be used to satisfy requests from the different users. You may need to add appropriate indexes to the materialized view for that to be a reasonable option, depending on how many distinct BOLOGIN values you expect.
    Justin
    Distributed Database Consulting, Inc.
    http://www.ddbcinc.com/askDDBC

  • Why materialized view taking hours and yet not created

    hi,
    i am trying to create the following MV
    create materialized view MV1
    force on demand
    start with date 1 next date2
    AS
    select query 1--> complex query that return approcimately 2 millions rows
    union all
    select query2 --> complex query that returns 300K rowsit has been taking hours i.e > 4 hrs and still unable to create the MV
    w/o the create materialized view statement i am able to return the results from the union of the 2 queries
    what might be the possibility ?
    tks & rdgs

    Issue could be due to the complexity of your query..Even i faced the same issue when i worked on materialized views.It was taking too long to create materialized view and then we splitted the query and created two materialized views.
    Finally created a View for those MV's.You can also try the same
    Materialized View Log
    When you create a materialized view using the FAST option you will need to create a view log on the base tables.A fast refresh uses materialized view logs to update only the rows that have changed since the last refresh.
    When DML changes are made to the master table's data, Oracle stores rows describing those changes in the materialized view log and then uses the materialized view log to refresh materialized views based on the base table. This process is called an incremental or fast refresh.Without a materialized view log, Oracle must reexecute the materialized view query to refresh the materialized view. This process is called a complete refresh.Usually, a fast refresh takes less time than a complete refresh.
    You can go through the below link
    http://www.lc.leidenuniv.nl/awcourse/oracle/server.920/a96567/repmview.htm
    Thanks
    Suni

  • Materialized view long transaction time

    I am using Oracle DB 11g R2 and created a materialized view log WITH SEQUENCE. I need to find out the exact date/time the transaction was made. I see that my MV log has the 'XID$$' column (NUMBER 22), but not sure how to determine the date/time from that. Is there another view/table I can join to get me that info? I see some have 'XID' column but they are RAW(8).
    Thanks
    Edited by: bobmagan on Feb 27, 2013 11:57 AM

    - CDC is at least as performant as materialized view logs. If you do asynchronous CDC, it performs better since you're not burdening the source transactions with the overhead of synchronously maintaining the materialized view logs.
    - CDC is at least as effective as materialized view logs. Since CDC is designed to publish changes to custom consumers where materialized view logs are designed to be used by Oracle to refresh a materialized view, it strikes me as a much safer solution. If someone comes along and creates a materialized view that starts using your materialized view log, for example, a solution that involves custom code to manipulate the materialized view is almost certainly going to fail.
    - CDC isn't an extra cost option so there shouldn't be a cost difference
    That leaves the question of simplicity. I'll certainly grant you that a materialized view log solution may appear simpler. But a lot of that simplicity advantage disappears over time. The fact that we're talking about doing things like querying relatively obscure data dictionary tables like all_summap, for example, is added complexity that a CDC-based solution doesn't need. But over time, I'd much rather maintain a CDC-based solution rather than hooking in to materialized view logs. If someone wants to build a materialized view and Oracle happens to be able to use the materialized view log you've created for your own CDC, the custom solution will stop working. Over time, Oracle introduces more and more functionality that allows the ROWID of a row to change (shrinking a table, flashback, etc.). If you're using CDC, Oracle will take care of making sure that all those things are presented to you correctly. If you're rolling your own solution, you have to test and ensure that your code handles all those cases correctly. When Oracle makes a change in some future release that you hadn't considered, you've got to notice the potential problem, code the fix, and test it. Most places are probably going to miss something and only discover that there is a problem when they do something like shrink a table and then find that their custom solution doesn't handle that gracefully.
    Justin

  • Materialized view Vs Streams - can you recommend one?

    We have many materialized views (for change data capture) based on rowid as the source doesn’t have primary keys. The source DB will be upgraded to 10/11g (from 9). Because the data would be exported and imported back, the rowids will be changed at the source.
    Consequently, the materialized views at the target need to be rebuilt. However, it is impossible to rebuild the materialized views timely due to huge volume.
    We are thinking about using Oracle Streams instead of materialized views. Any advice would be greatly appreciated.
    hb

    With streams, primary are not require but your updates are not guarantee. If you have duplicates in your data, it will updates both which may or may not be what you want. BTW. Streams will not replicate table with rowid. I am assuming those rowid were required because you are outer joins with MVs.
    If you want to stick with MVs, you can take exports of the tables, import after the upgrade and build the MVs with the prebuilt table option. It's a lot quicker then trying to recreate the MV or doing complete refresh over the WAN.

  • Importing materialized views from database into physical layer

    Hi,
    I have created materialized view in the database. When I try to import the materialized view into the physical layer in OBIEE 10G (using the import from database option), it is not showing in the list of available object. I have selected all the object types (tables,views etc.). Can you please let me know how to import the existing MVs in the database into the physical layer.
    Regards
    Vinodh.
    Edited by: user493441 on Jul 7, 2012 4:11 PM

    Hi Vinod,
    Refer the below links.
    Materialized Views in OBIEE
    http://gerardnico.com/wiki/database/oracle/materialized_view
    Concept of materialized views in creating datawarehouse?????
    Hope this help's
    Thanks
    Satya

  • Oracle Materialized views | Reporting

    I have a requirement as follows:
    Requirement:
    We need to create a Reporting DB to use for Reporting and a Transactional DB will be in separate Host. Basically we need to pull data from a set of tables from Transactional DB and move to Reporting DB schema at proper intervals.
    We might have to get data from different column from different tables and store it in a single table/multiple tables in Reporting DB.
    Solution (Please validate):
    I am planning to use Oracle Materialized views in the same host as Transactional DB to achieve the following part of requirment
    "We might have to get data from different column from different tables and store it in a single table/multiple tables in Reporting DB."
    and then to use Oracle streams to move it in scheduled interval to Reporting DB.
    Is it feasible?
    Or please suggest some solution.
    Thanks,
    Appu

    Hi,
    You design is too complex, why use 2 technologies if one is sufficient ? If data amount permits I would do fast refresh MV (if possible, based on required joins and aggregations) over db link directly in the reporting database.
    --romas                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           

  • Materialized view not being used in the report

    I have had a materialized view (MV) for a particular report. Recently, the report definition has changed little bit, so the existing MV is not being used by the report anymore. I copied the code Discoverer's SQL Inspection and recreated the materialized view. But still it is not working. Obviously, I am missing something at the database level. Does anyone have any idea? The database is 9i and Discoverer is 9.0.2. Thank you!

    The SQL that you see from the Inspect SQL option will provide you with the SQL that Discoverer sends to the database. The database then may do a query rewrite to point to an available materialized view if available. This rewrite won't be seen from the inspect sql option. You need to check at the database level to verify if a query rewrite did in fact take place.
    You may want to check the section titled "Query Rewrite with Materialized Views" from Ch1 - "Introduction to the Optimizer" in the Oracle9i Database Performance Tuning Guide and Reference, Release 2 (9.2), Part Number A96533-02, available at http://download-uk.oracle.com/docs/cd/B10501_01/server.920/a96533/optimops.htm#37287
    Regards
    Abhinav Agarwal
    Oracle Business Intelligence Product Management
    http://www.oracle.com/bi
    http://www.oracle.com/technology/documentation/bi_ee.html
    http://www.oracle.com/technology/software/products/ias/htdocs/101320bi.html
    http://oraclebi.blogspot.com/

  • Fast Refresh Nested Materialized View problem in ORACLE 9i 9.2.0.7

    Hello
    My problem is in creating fast refresh nested materialized view in oracle 9i
    In below is an example of my problem
    ( I need to say when I run this example in Oracle 11g all things is OK )
    create table ali.alitest1(id number primary key,n1 number,n2 number);
    create table ali.alitest2(id number primary key,n3 number);
    CREATE MATERIALIZED VIEW LOG ON ali.alitest1 WITH ROWID,PRIMARY KEY ,SEQUENCE
    (n1,n2)
    INCLUDING NEW VALUES;
    CREATE MATERIALIZED VIEW LOG ON ali.alitest2 WITH ROWID,PRIMARY KEY ,SEQUENCE
    (n3)
    INCLUDING NEW VALUES;
    CREATE MATERIALIZED VIEW ali.alitest1_mv
    REFRESH WITH PRIMARY KEY FAST
    AS
    select id,n1 from ali.alitest1;
    CREATE MATERIALIZED VIEW LOG ON ali.alitest1_mv WITH ROWID,PRIMARY KEY ,SEQUENCE
    (n1)
    INCLUDING NEW VALUES;
    CREATE MATERIALIZED VIEW ali.alitest2_mv
    REFRESH WITH PRIMARY KEY FAST
    AS
    select t1.id,t1.n1,t2.n3,t1.rowid "t1_rowid",t2.rowid "t2_rowid" from ali.alitest1_mv t1,ali.alitest2 t2 where t1.id=t2.id;
    SQL Error: ORA-12053: this is not a valid nested materialized view
    12053. 00000 - "this is not a valid nested materialized view"
    *Cause:    The list of objects in the FROM clause of the definition of this
    materialized view had some dependencies upon each other.
    *Action:   Refer to the documentation to see which types of nesting are valid.
    do you know what is problem ?
    thanks

    Take look for this link :
    http://rwijk.blogspot.com/2009/08/fast-refreshable-materialized-view.html

  • Creating a Materialized View in Oracle 8i

    Hello -
    What are the steps and privileges required to create a materialized view in Oracle 8i?
    Thanks

    To create a materialized view in your own schema:
    You must have been granted the CREATE MATERIALIZED VIEW system privilege and either the CREATE TABLE or CREATE ANY TABLE system privilege.
    You must also have access to any master tables of the materialized view that you do not own, either through a SELECT object privilege on each of the tables or through the SELECT ANY TABLE system privilege.
    To create a materialized view in another user's schema:
    You must have the CREATE ANY MATERIALIZED VIEW system privilege.
    The owner of the materialized view must have the CREATE TABLE system privilege. The owner must also have access to any master tables of the materialized view that the schema owner does not own (for example, if the master tables are on a remote database), and to any materialized view logs defined on those master tables, either through a SELECT object privilege on each of the tables or through the SELECT ANY TABLE system privilege.
    Thanks
    Manish

  • Database replication with updatable materialized view in oracle 10gR2

    I neet to set up 1 central server and two local databases ....the local database will hold materialized view....now how to replicate data...in this scenario...please help as soon as possible...i am in rush.....
    the database i use is oracle 10g Release 2
    Edited by: user9932019 on Sep 4, 2009 2:25 AM

    It's not a process that can be explained in a forums posting. You have to understand the steps.
    Here are some other examples :
    http://www.orafaq.com/wiki/Scripts#Oracle_Advanced_Replication_Scripts

Maybe you are looking for

  • Airport Express, Airport Admin 4.2 and Windows Vista

    If you, like me, have bought a Airport Express and cant get Airport Admin upgraded to 5.2 (which supports vista), you can still make it work. Start by resetting the Airport express to factory defaults, by pressing and holding in the lill button on th

  • Optical drive is very loud - why?

    My optical drive is so loud it sounds like it's ready for takeoff. I've only had my late 2008 MacBook Pro for a couple of months and had no problems with CD's until just recently. They play just fine, but the drive keeps spinning at top speed through

  • Idvd plays some movie clips in a widescreen preview

    I can't figure out how to keep some clips from going into widescreen preview. They are marked to play in 4:3 mode. Of the 15 clips four play in widescreen preview in the preview mode. Help!

  • ORA-01114: IO error writing block to file

    I am trying to create an index on a RAC database. I have tried this in two different schemas with two different tablespaces. I am not getting the standard "unable to extend segment" when you are out of space. I get: Tried creating an index: ERROR at

  • ITAB_NON_NUMERIC_COMPONENT" in the "generation of scrambling programs for non-cluster tables

    Dear Experts, We have are experiencing issues in standalone scrambling, we are getting error" ITAB_NON_NUMERIC_COMPONENT" in the "generation of scrambling programs for non-cluster tables" Please help with the needful urgently. Thanks