LSMW and material view

Hi,
I'm using LSMW to upload material master data. The import method is "standard batch/direct input": object "0020" (material master), method "0000", program name "rmdatind" and program type "D" (direct input).
I have created a project/subproject for basic view 1 & 2 and it works fine.
I have created a second subproject for division view (MRP......) but when i run it, the system asks me all the mandatory fields fior basics views 1 &2. The problem is: how makes the system know that i want to add views to an existing not to create a new item??
The common field in my to data files is MATNR
Can some one help me with this problem?
Thanks

I solved the error on field MARC-MMSTA. It was a mistake in the field mapping.
And now it works with only MATNR, MBRSH, MTART
Thanks
Edited by: Simon MAES on Jun 22, 2009 3:42 PM

Similar Messages

  • Table and Materialized View in different namespaces?

    I've just faced something completly new for me. It appears that there are two objects with the same name and owner. Table and Materialized View have the same names and when I look into system dictionary I can se sth. like that:
    OWNER OBJECT_NAME OBJECT_ID DATA_OBJECT_ID OBJECT_TYPE NAMESPACE
    USER_A USER_TABLE 159381 159381 TABLE 1
    USER_A USER_TABLE 159382 MATERIALIZED VIEW 19
    (I couldn't find how to write above with const length font).
    Two object in different namespace? I thought that Tables and Materialized Vievs have the same namespace.
    Can you please tell me how can I create objects to achieve above result? I would also be grateful if you tell me where to find that topic in documentation.

    Perfectly normal.
    SQL> select object_name, object_type from user_objects where object_name = 'TEST_MV';
    no rows selected
    SQL>
    SQL> create materialized view test_mv
      2  as
      3  select sysdate from dual;
    Materialized view created.
    SQL>
    SQL> select object_name, object_type from user_objects where object_name = 'TEST_MV';
    OBJECT_NAME                                        OBJECT_TYPE
    TEST_MV                                            TABLE
    TEST_MV                                            MATERIALIZED VIEW
    SQL>
    SQL> drop materialized view test_mv;
    Materialized view dropped.
    SQL>
    SQL> select object_name, object_type from user_objects where object_name = 'TEST_MV';
    no rows selected
    SQL>

  • Authorization for material type and material views

    Hello all,
    I would need to restrict a user group, in creation (MM01) and modification of material master, based of type material and material views.
    The authorization, for each user should be:
    - view, modify and create of all views, except accounting (B) for type material ZFER;
    - view, modify and create of all views for type material ZOFF.
    I tried to create 2 roles in PFCG with the following authorization objects:
    1) M_MATE_MAR (Material Master: Material Types)  ACTVT = *, BEGRU = ZFER and M_MATE_STA (Maintenance Statuses) ACTVT = *, STATM = A,C, D, E, F, G,K, L, P, Q, S, V, X, Z (excluding B)
    2) ) M_MATE_MAR  ACTVT = *, BEGRU = ZFER and M_MATE_STA ACTVT = *, STATM = B
    but the effect is to be authorized, to all view for material type ZFER and ZOFF.
    I have already updated the authorization group of the type materials (OMS2).
    Is there a solution for this problem?
    (component version SAP ECC 6.0)
    Thanks.
    Regards,
    Luca

    I tried to create 2 roles in PFCG with the following authorization objects: 1) M_MATE_MAR (Material Master: Material Types) ACTVT = *, BEGRU = ZFER and M_MATE_STA (Maintenance Statuses) ACTVT = *, STATM = A,C, D, E, F, G,K, L, P, Q, S, V, X, Z (excluding B) 2) ) M_MATE_MAR ACTVT = *, BEGRU = ZFER and M_MATE_STA ACTVT = *, STATM = B
    - Are both these roles assigned to the same user? then your purpose is not solved, It is more or less like giving full authorization.
    - One role should be
    M_MATE_MAR (Material Master: Material Types) ACTVT = *, BEGRU = ZFER and M_MATE_STA (Maintenance Statuses) ACTVT = *, STATM = A,C, D, E, F, G,K, L, P, Q, S, V, X, Z (excluding B) for view, modify and create of all views, except accounting (B) for type material ZFER. This should be assigned to one user
    - Second role should be
    M_MATE_MAR ACTVT = *, BEGRU = ZOFF and M_MATE_STA ACTVT = *, STATM = * for view, modify and create of all views for type material ZOFF. This role should be assigned to the second user.
    Regards,
    Subbu

  • Oracle equals_path condition NOT working with table and materialized view

    The user i am using is xdb with dba role.
    1.When i try to use the statement
    SELECT PATH FROM xdb.path_VIEW
    WHERE
    EQUALS_PATH(res, '/home/OE/PurchaseOrders/2002')=1
    the result is
    /home/OE/PurchaseOrders/2002
    2. When i drop the path_view and recreated it like materialized view with statement
    create MATERIALIZED view path_view as
    select /*+ ORDERED */ t2.path path, t.res res,
    xmltype.createxml(xdb.xdb_link_type(NULL, r2.xmldata.dispname, t.name,
    h.name, h.flags, h.parent_oid, h.child_oid),
    'http://xmlns.oracle.com/xdb/XDBStandard.xsd', 'LINK') link,
    t.resid
    from ( select xdb.all_path(9999) paths, value(p) res, p.sys_nc_oid$ resid,
    p.xmldata.dispname name
    from xdb.xdb$resource p
    where xdb.under_path(value(p), '/', 9999)=1 ) t,
    TABLE( cast (t.paths as xdb.path_array) ) t2,
    xdb.xdb$h_link h, xdb.xdb$resource r2
    where t2.parent_oid = h.parent_oid and t2.childname = h.name and
    t2.parent_oid = r2.sys_nc_oid$
    then the equals_path condition STOP working !!!
    3. The same experiment, but i recreate it like table
    create table path_view as .... using the rest of the statement ...
    Can someone help me to understand why equals_path is NOT working on table and materialized view !

    Thanks Jonah. I was under the impression that I already had it but seems like it has to be a direct priv - thru a role doesn't work.
    I granted the reqd privs and then it worked fine. Thx for your help!

  • Differences between view and materialized view

    Hello,
    Please tell me the Differences between view and materialized view in oracle 9i.
    Thanks and regards
    Madhuri

    How can I create index in a view?
    Please read reply of Justin Sir.
    Regards
    Girish Sharma

  • What is the difference between view and materialized views

    Hi
    What is the difference between view and materialized view ? can we update the base table using views

    can we update the base table using viewsYes:
    VIEWS
    1. an updatable view is one that lets you perform DML on the underlying table
    (see Oracle Database Concepts 10g - 5 Schema Objects)
    2. non-updatable view requires INSTEAD OF Triggers
    (see Oracle Database Concepts 10g - 22 Triggers)
    SNAPSHOTS
    You can have updateable (and writeable) snapshots - in updateable (writeable) MV replication.
    Oracle uses snapshots (Materialized Views - MV) for two different purposes:
    1. replication
    2. automated Query Rewrite facility (first introduced in Oracle Discoverer, later included in Oracle database 8i).
    Replication types in Oracle are:
    a) Basic replication (MV replication)
    - transaction based
    - row-level
    - asynchronous from master table to MV (Materialized View)
    - DML replication only
    - database 7 / 8.0 / 8i / 9i / 10g
    - Standard and Enterprise Edition
    1. Read-only MV replication
    2. Updateable MV replication:
    2.1 asynchronous from MV to master
    2.2 synchronous from MV to master
    3. Writeable MV replication
    b) Multimaster replication
    - transaction based
    - row-level or procedural
    - asynchronous or synchronous
    - DML and DDL replication
    - database 7 / 8.0 / 8i / 9i / 10g
    - Enterprise Edition only
    1. row-level asynchronous replication
    2. row-level synchronous replication
    3. procedural asynchronous replication
    4. procedural synchronous replication
    c) Streams replication
    - (redo) log based
    - row-level
    - asynchronous
    - DML and DDL replication
    - database 9i / 10g (10g has Down Streams Capture)
    - Enterprise Edition only (Standard Edition 10g can execute Apply process)
    Regards,
    Zlatko Sirotic

  • Creation of Materialized view and Materialized view log.

    I wanted to create materialized view with 'REFRESH FAST ON COMMIT' option.
    1) Table1 --it is partitioned range + list -- Added primary key
    2) view1   -- having primary keys on view's base table
    Steps:
    1) create materialized view log on Table1 ; -- default primary key
    2) create materialized view log on view1.  --- It is giving below error.
    ORA-00942: table or view does not exist
    i wanted to create Materialized view like below
    create materialized view
    REFRESH fast ON commit
    as
    select ...
    ... from table1
    where c1 in (select c1 from view1 where ... );
    Question:
    1) As i am getting above error while creating MV log on view. Can we create MV log on view or we have to create MV log on view base table?
    2) To create MV with ''REFRESH FAST ON COMMIT' option , do we need to have primary key on master tables? 
    Any pointers on this will really helpful.
    Thanks
    Prasad

    Also created MV LOG on 3 tables and tried with joins ..
    create materialized view
    REFRESH fast ON commit
    as
    select ...
    ... from table1 , tab2 t2,tab3 t3
    where ....
    and ...
    Get same error ORA-12052: cannot fast refresh materialized view AVSYS.EVENT_LOG_MV
    2052. 00000 -  "cannot fast refresh materialized view %s.%s"
    *Cause:    Either ROWIDs of certain tables were missing in the definition or
               the inner table of an outer join did not have UNIQUE constraints on
               join columns.
    *Action:   Specify the FORCE or COMPLETE option. If this error is got
               during creation, the materialized view definition may have be
               changed. Refer to the documentation on materialized views.

  • DBMS_METADATA.GET_DDL and Materialized View

    hi gurus,
    In 10gR2, i have created a materialized view EMP_MV with a simple structure.
    I wanted to get the DDL of EMP_MV.
    I used DBMS_METADATA to get the DDL,
    select DBMS_METADATA.GET_DDL('MATERIALIZED_VIEW','EMP_MV','TARGET') into v_return from dual;
    Output
    CREATE MATERIALIZED VIEW "TARGET"."EMP_MV"
    ORGANIZATION HEAP PCTFREE 10 PCTUSED 40 INITRANS 1 MAXTRANS 255 NOCOMPRESS LOGGING
    STORAGE(INITIAL 65536 NEXT 1048576 MINEXTENTS 1 MAXEXTENTS 2147483645
    PCTINCREASE 0 FREELISTS 1 FREELIST GROUPS 1 BUFFER_POOL DEFAULT)
    TABLESPACE "TARGET_TS_01"
    BUILD IMMEDIATE
    USING INDEX PCTFREE 10 INITRANS 2 MAXTRANS 255
    STORAGE(INITIAL 65536 NEXT 1048576 MINEXTENTS 1 MAXEXTENTS 2147483645
    PCTINCREASE 0 FREELISTS 1 FREELIST GROUPS 1 BUFFER_POOL DEFAULT)
    TABLESPACE "TARGET_TS_01"
    REFRESH FAST ON DEMAND
    WITH PRIMARY KEY USING DEFAULT LOCAL ROLLBACK SEGMENT
    DISABLE QUERY REWRITE
    AS select empid,empname,address from web.emp
    Is there any way to get only SELECT part of this MV, ie select empid,empname,address from web.emp directly from dictionary without any string manipulation?
    tia,
    newbie

    Yes you can do it. By using INSTR and SUBTR against the result of GET_DDL function
    Try this:
    select substr(DBMS_METADATA.GET_DDL('MATERIALIZED_VIEW','EMP_MV','TARGET'),instr(DBMS_METADATA.GET_DDL('MATERIALIZED_VIEW','EMP_MV','TARGET'),'select'),1000)
    into v_return from dual;- - - - - - - - - - - - - - - - - - - - -
    Kamran Agayev A. (10g OCP)
    http://kamranagayev.wordpress.com
    [Step by Step install Oracle on Linux and Automate the installation using Shell Script |http://kamranagayev.wordpress.com/2009/05/01/step-by-step-installing-oracle-database-10g-release-2-on-linux-centos-and-automate-the-installation-using-linux-shell-script/]

  • Truncate table and materialized view log

    I user oracle 10 R2
    I have a table and on that table a materialized view log.
    I execute in a pl/sql procedure:
    1) execute immediate('drop materialized view log on tab1');
    then:
    2) execute immediate('truncate table tab1');
    3) Now I insert a lot of records in tab1
    4) execute immediate('create materialized view log on tab1 WITH rowid INCLUDING NEW VALUES');
    When I create the materialized view log I recieved this message:
    ora32321: refresh fast on tab2 unsupported after detail table truncate
    Why?

    Refresh fast after truncate operation on container table is not supported, regardless the container table is or is not partitioned.
    Perform a refresh complete.
    ORA-32321 :
    Cause:     A detail table has been truncated and no materialized view
         supports fast refersh after a detail table has been truncated
    Action:     Use REFRESH COMPLETE. Note: you can determine why your
         materialized view does not support fast refresh after TRUNCATE
         using the DBMS_MVIEW.EXPLAIN_MV() API.

  • Help with query rewrite and materialized views

    Hello everybody,
    I'm currently learning how to use Oracle (10G Enterprise) and in particular, Materialized Views.
    I seem to have a problem making the optimizer use a materialized view. I have already set the OPTIMIZER_MODE, QUERY_REWRITE_ENABLED and QUERY_REWRITE_INTEGRITY as needed.
    I need to create a materialized view for the following query:
    Q1:
    SELECT PS_SUPPKEY, PS_PARTKEY, PS_SUPPCOST
    FROM PARTSUPPLIER E, PART WHERE PS_PARTKEY=P_PARTKEY and (lower(P_COMMENT) LIKE ''_o_a\%'' or lower(P_COMMENT) LIKE ''_o_u\%'')
    and PS_SUPPCOST =
    (SELECT min( PS_SUPPCOST)
    FROM PARTSUPPLIER I
    WHERE E.PS_PARTKEY=I.PS_PARTKEY)'
    I created it using the following code:
    CREATE MATERIALIZED VIEW mv_q1
    ENABLE QUERY REWRITE
    AS SELECT PS_SUPPKEY, PS_PARTKEY, PS_SUPPCOST
    FROM PARTSUPPLIER E JOIN PART ON (PS_PARTKEY=P_PARTKEY)
    WHERE lower(P_COMMENT) LIKE '_o_a%' or lower(P_COMMENT) LIKE '_o_u%'
    and PS_SUPPCOST=
    (SELECT min( PS_SUPPCOST)
    FROM PARTSUPPLIER I
    WHERE E.PS_PARTKEY=I.PS_PARTKEY);
    I have created the statistics using:
    execute dbms_stats.gather_table_stats('frandres',' mv_q1');
    execute dbms_stats.gather_table_stats('frandres','PARTSUPPLIER');
    execute dbms_stats.gather_table_stats('frandres','PART');
    Both partsupplier and part are tables and not views.
    When executing Q1, the plan does not use the materialized view. Furthermore, when using explain rewrite:
    DECLARE
    qrytxt VARCHAR2(3000) := 'SELECT PS_SUPPKEY, PS_PARTKEY, PS_SUPPCOST
    FROM PARTSUPPLIER E, PART WHERE PS_PARTKEY=P_PARTKEY and (lower(P_COMMENT) LIKE ''_o_a\%'' or lower(P_COMMENT) LIKE ''_o_u\%'')
    and PS_SUPPCOST =
    (SELECT min( PS_SUPPCOST)
    FROM PARTSUPPLIER I
    WHERE E.PS_PARTKEY=I.PS_PARTKEY)';
    BEGIN
    dbms_mview.EXPLAIN_REWRITE
    (qrytxt,'MV_Q1','MV_Q1');
    END;
    I get the following message:
    MESSAGE
    QSM-01150: query did not rewrite
    QSM-01263: query rewrite not possible when query references a dictionary table o
    r view
    QSM-01219: no suitable materialized view found to rewrite this query
    What I can't understand is why it says I am referencing the dictionary or a view?
    If I remove the (lower(P_COMMENT) LIKE ''_o_a\%'' or lower(P_COMMENT) LIKE ''_o_u\%'') condition to the query (using the same materialized view), I get the following message from EXPLAIN_REWRITE:
    MESSAGE
    QSM-01150: query did not rewrite
    QSM-01219: no suitable materialized view found to rewrite this query
    Which is reasonable.
    I don't know if the like condition is messing up my materialized view. Can anyone please help?
    Thanks a lot in advance.
    Edited by: user12072111 on Oct 29, 2009 9:43 PM

    Bingo!
    The 10.2.0.3 patch set is supposed to fix this ( [List of bugs fixed (MVs)|http://www.dbatools.net/doc/bug10203.html#MVIEW] )
    In particular:
    5052568      Query rewrite does not work for SQL with LIKE clause.
    Thank you very much for your message!
    The downside is that I'm only using Oracle for educational purposes and consequently have no Metalink id, so I can't install the patch. Thanks a lot though!

  • MATERIALIZED VIEW and MATERIALIZED VIEW LOG

    Hello,
    I have the following table
    create table My_price
    (price_id number(10),
    product_id number(10),
    price_date date,
    price_value number(10,2));
    I want to create the following materialized view
    create materialized view Last_Price_Date
    refresh
    on commit complete
    as
    select max(price_date) as max_date, product_id from my_price group by product_id;
    Do I have to create materialized view log ? Will my materialized view be refresh on commit without materialized view log ?

    As a student the requisite first task is always to study. Thus your assignment is to go to http://tahiti.oracle.com and read the concept and architecture docs on Materialized Views so that you can learn about the different types of MVs and how and when they are refreshed. There you will learn about what ON COMMIT means.
    Then please turn your "I want to create" into an "I created it." Then, having read the docs, you will be able to observe how your MV behaves.
    PS: Your SELECT statement is not syntactically correct. Start by fixing it so that it works in SQL*Plus.

  • Instr command in APEX and materialized view

    This worked fine up until we changed it to use a materialized layer. P6080_DEPARTMENT, P6080_TITLE and P6080_ROLE are all Multi-Select lists. ACMV is the materialized view. I have been trying multiple things but nothing works.
    ( instr(':'||:P6080_DEPARTMENT||':',':'||ACMV.DEPARTMENT||':') > 0 or
    :P6080_DEPARTMENT is NULL or :P6080_DEPARTMENT = 'ALL') and
    ( instr(':'||:P6080_TITLE||':',':'||ACMV.TITLE||':') > 0 or
    :P6080_TITLE is NULL or :P6080_TITLE = 'ALL') and
    ( instr(':'||:P6080_ROLE||':',':'||ACMV.ROLE||':') > 0 or
    :P6080_ROLE is NULL or :P6080_ROLE = 'ALL')
    I can run this in a sql window and get the results using the following for Department
    when if use the values from the debugging output.
    select business_name from account_contacts_mv acmv
    where instr(':ADMINISTRATION:COMPLIANCE:ENGINEERING:EXECUTIVE:FINANCE:HR:IT:LEGAL:',':'||ACMV.department||':')>0
    This is a little frustrating and any help will be appreciated.
    KDP

    KDP,
    what is your actual problem. Do you get an error or do you suffer performance problems?
    Patrick
    My APEX Blog: http://inside-apex.blogspot.com
    The ApexLib Framework: http://apexlib.sourceforge.net
    The APEX Builder Plugin: http://sourceforge.net/projects/apexplugin/

  • PL/SQL Proc, execute immediate and materialized view 9.2.0.6

    Hello,
    Environement description: Sun Solaris 8 , Oracle database 9.2.0.6
    I've a problem trying to execute this PL/SQL Procedure:
    I'm loged in with PMU user
    CREATE OR REPLACE PROCEDURE PMU.PROC_TEST_PMU_C035 (part_arrete in integer, part_session in integer) AS
    lv_p_arrete number     := part_arrete;
    lv_p_session number     := part_session;
    lv_stmt     varchar2(31000);
    BEGIN
    lv_stmt := ' ';
    lv_stmt := lv_stmt || 'CREATE MATERIALIZED VIEW 'PMU''.''TEST_PMU_C035'' ';
    lv_stmt := lv_stmt || 'TABLESPACE PMU_8M_DATA ';
    lv_stmt := lv_stmt || 'BUILD IMMEDIATE ';
    lv_stmt := lv_stmt || 'REFRESH COMPLETE AS ';
    lv_stmt := lv_stmt || 'SELECT * FROM ACTION ';
    lv_stmt := lv_stmt || 'WHERE LIBELLE IN ( ''SOCIETE 1'', ''SOCIETE 2'', ''SOCIETE 3'' ) ;';
    dbms_output.put_line ( lv_stmt) ;
    execute immediate ( lv_stmt);
    END;
    When I comment the line : execute immediate ( lv_stmt); It works fine and my statement appear on the screen:
    CREATE MATERIALIZED VIEW PMU.TEST_PMU_C035 TABLESPACE PMU_8M_DATA BUILD
    IMMEDIATE REFRESH COMPLETE AS SELECT LIBELLE FROM ACTION WHERE LIBELLE IN (
    'SOCIETE1', 'SOCIETE2', 'SOCIETE3' ) ;
    When I execute manually this query it works.
    But when I try to do the execute immediate, it gives me this error:
    BEGIN "PMU"."PROC_TEST_PMU_C035" ( 13, 14); END;
    ERROR at line 1:
    ORA-00911: invalid character
    ORA-06512: at "PMU.PROC_TEST_PMU_C035", line 15
    ORA-06512: at line 1
    Action Table has this description and datas:
    SQL> desc action
    Name Null? Type
    ISIN NOT NULL VARCHAR2(20)
    LIBELLE VARCHAR2(100)
    SQL>
    ISIN LIBELLE
    FR1 SOCIETE 1
    FR2 SOCIETE 2
    FR3 SOCIETE 3
    FR4 SOCIETE 4
    FR5 SOCIETE 5
    FR6 SOCIETE 6
    FR7 SOCIETE 7
    FR8 SOCIETE 8
    FR9 SOCIETE 9
    FR10 SOCIETE 10
    FR11 SOCIETE 11
    This is a sample description of my probleme because the real case is on multiple partition tables with million rows, but the problem is the same with this sample.
    My question is why it doesn't work ? Could anybody help me ?
    Thanks In advance.
    Loic

    Yes but you did not show where you want the parametersOK this is my Original Query :
    CREATE OR REPLACE PROCEDURE "PMU"."PROC_TEST_PMU_C035" (part_arrete in integer, part_session in integer)AS
    lv_p_arrete integer := part_arrete;
    lv_p_session integer := part_session;
    lv_stmt varchar2(31000);
    BEGIN
    lv_stmt := 'CREATE OR REPLACE MATERIALIZED VIEW PMU.TEST_PMU_C035 ';
    lv_stmt := lv_stmt || ' TABLESPACE PMU_8M_DATA ';
    lv_stmt := lv_stmt || ' BUILD IMMEDIATE ';
    lv_stmt := lv_stmt || ' REFRESH COMPLETE AS ';
    lv_stmt := lv_stmt || ' select CD_SOCIETE, MONTANT, MOIS, TYPEDET, LIEUCONS, DETPEA, PERSPHYS, SECTDET, PAYSDET, ZONEDET, CSPDET, AGEDET, TRMONT, NATINSFI, MATURITE, MONNAIE, DEVISEISO, SECTEMT, PAYSEMT, ZONEEMT, ENCRSDEB, NBCPTIT, TYPEFLUX, CONTRAT, CODISIN, LIBELTIT, SEUILDET, PAYSCTP, NBTIT, SEUILA1, SEUILA2, SEUILM1, SEUILM2, SEUILB1, SEUILB2, SEUILQ1, SEUILQ2, TXEVOL, NBCPTITPEA, NBCPTITPPP, ';
    lv_stmt := lv_stmt || ' NO_PCI || ''-'' || SECTDET || ''-'' || ZONEDET || ''-'' || MONNAIE || ''-'' || SECTEMT || ''-'' || DETPEA || ''-'' || PERSPHYS || ''-'' || (CASE WHEN TYPEDET IN (''DCL'', ''DCG'') THEN ''DCL'' ';
    lv_stmt := lv_stmt || ' ELSE NVL(TYPEDET,'''') ';
    lv_stmt := lv_stmt || ' END ) || ''-'' || (CASE WHEN NATINSFI in (''OBL'', ''EMT'', ''BTR'', ''CDD'', ''CDE'', ''CPP'', ''BTS'', ''MIB'') THEN ''OBL'' ';
    lv_stmt := lv_stmt || ' ELSE NVL(NATINSFI,'''') ';
    lv_stmt := lv_stmt || ' END) || ''-'' ||(CASE WHEN MATURITE IN (''A0'', ''A1'') THEN ''AC'' ELSE NVL(MATURITE,'''') END) || ''-'' ||(CASE WHEN PAYSEMT IN (''FR'',''MC'') THEN ''F1'' ';
    lv_stmt := lv_stmt || ' WHEN PAYSEMT IN (''DE'',''AT'',''BE'',''ES'',''FI'',''GR'',''IE'',''IT'',''LU'',''NL'',''PT'',''SI'', ''4F'') THEN ''ZE'' ';
    lv_stmt := lv_stmt || ' WHEN PAYSEMT IN (''BG'',''CY'',''DK'',''EE'',''HU'',''LV'',''LT'',''MT'',''PL'',''RO'',''GB'',''SK'',''SE'',''CZ'', ''4C'', ''4D'', ''4H'', ''4E'', ''4Z'', ''JE'') THEN ''ZU'' ';
    lv_stmt := lv_stmt || ' ELSE ''ZR''';
    lv_stmt := lv_stmt || ' END ) AS CLE';
    lv_stmt := lv_stmt || ' from PMU_ESLD_ESTD partition(PMU_M13_S14) e ,';
    lv_stmt := lv_stmt || ' PMU_ESLD_ESTD_SPPRO partition(PMU_M13_S14) a';
    lv_stmt := lv_stmt || ' where e.PART_ARRETE = '||lv_p_arrete ;
    lv_stmt := lv_stmt || ' AND e.PART_ENV = ''BCE''' ;
    lv_stmt := lv_stmt || ' AND e.PART_SESSION = '||lv_p_session ;
    lv_stmt := lv_stmt || ' and e.ID = a.ID_ESTD ';
    lv_stmt := lv_stmt || ' and e.CD_STATUT = ''VE'' ' ;
    lv_stmt := lv_stmt || ' and e.TYP_MONTANT = ''33'' ; ' ;
    execute immediate lv_stmt;
    END;
    Thanks

  • Map Viewer Query Rewriting for Dynamic themes and  Materialized Views.

    Hi,
    I am usng a WMS request to render FOI points in my map.
    Internally query rewrite is happening in Mapviewer for this dynamic theme and my data points query is getting converted as
    select FROM
    ( select status, shape from MatView.MyTab where id = '3' )
    WHERE MDSYS.SDO_FILTER(shape, MDSYS.SDO_GEOMETRY(2003, 4283, NULL, MDSYS.SDO_ELEM_INFO_ARRAY(1, 1003, 3), MDSYS.SDO_ORDINATE_ARRAY(144.948120117188,-37.8162934802451,144.950866699219,-37.8141237016045)), 'querytype=WINDOW') = 'TRUE'
    here the rewritten query is not correct and is throwing exceptions in mapviewer log
    How can I make this query to be written correctly.
    (My orginal query before rewrite is: select status,shape from MatView.MyTab where id='3' )
    I am using a materialised view : MatView is a materialized view.
    When I used normal tables, the query is re written correctly.But for this materialized view this is happening.
    How can I correct the error?
    Is this has something to do with some Spatial Indexing in Materialised view or Query Rewriting for materialized view?
    Edited by: 841309 on Mar 10, 2011 11:04 PM

    Oops!
    The Materialized view was not accessible from the schema I tried :)
    And so when I gave permissions,it formed the correct query.
    So if permission is not there,map viewer will rewrite the query in a wrong way! New information.

  • Performance difference between tables and materialized views

    hi ,
    I created a materialized view on a query that involves partition table in it.
    When i used the same query and created a table out of it <create table xyz as select * from (the query)> ,the table got created quickly.
    So does that mean performance wise creating table is faster than creating/refreshing the materialized view ?or is that due to the refresh method i use ?Currently i use a complete refresh

    I created a materialized view on a query that involves partition table in it.
    When i used the same query and created a table out of it <create table xyz as select * from (the query)> ,the table got created quickly.
    So does that mean performance wise creating table is faster than creating/refreshing the materialized view ?or is that due to the refresh method i use ?Currently i use a complete refresh Well, for starters, if you created the materialized view first and then the standard table, the data for the second one has already been fetched recently and so will reduce your I/O due to caching, and will therefore be quicker. There are also other factors such as the materialized view creating other internal bits that are required to allow for refreshes to be done quickly, such as the primary key etc which you haven't created on your second creation.
    What you have shown is that two completely different statements running at different times, appear to operate with different speed. It is not a comparison of whether the materialized view is slower or quicker than the create table statement.

Maybe you are looking for

  • Istalling oracle 11g on windows vista

    Hi, i need to install oracle 11g on windows vista, unfortunately i cannot able do to that, becase after double cliking on the setup a messege like this one came out: OUI-10151: There was an error while loading library.generalQueries. Stop installatio

  • Solved - Group Fields for Vendor Master Records in IMG

    This was the solution. The new field's data element I added to LFB1 did not have the "change document" field checked.  I made that change and now that field shows up in IMG. Hello all, I added an append structure to the table LFB1.  This structure ha

  • Trouble printing black and white

    Friends, I'm trying to print black and white on an imac i7, snow leopard, hp premium plus all in one (309g) printer. The prints have a slight purple cast. It is highly noticeable when the prints are placed next to older black and whites printed with

  • APP-PAY-07092: This action is invalid for the current record.

    Unable to access employees assignment panel in order to make updates within oracle HR receiving this error.How to fix this.

  • [Flex Hero] How to put Google Mobile Ads in AIR on Android

    Hi, everyone I am developing a free application with Adobe Flash Builder "Burrito". Thank you to Flex SDK team, the SDK is very easy to implement the application. My question is, Is it possible to put Google Mobile Ads in the application (for example