ORA-14291: cannot EXCHANGE a composite partition with a non-partitioned ta

How do I resolve the below issue. I need to create a temp table and then do a exchange partition to the temp table using certain condition . The main table
edc.edc_log_test has partition and subpartition. I used the below sql to create the temp table. How can I create the temp table with partition so that I do not get the mentioned error.
edc.edc_log_test has
PARTITION BY RANGE(CAPTURE_DATE)
SUBPARTITION BY LIST(TRAN_NBR)
l_ddl := 'create table ' || p_object_owner_in || '.' ||
p_part_subpart_name || ' as select * from ' ||
p_object_owner_in || '.' || p_object_name_in || ' where 1=2';
l_ddl := ' ALTER TABLE ' || p_object_owner_in || '.' ||
p_object_name_in || ' EXCHANGE PARTITION ' ||
p_part_subpart_name || ' WITH TABLE ' ||
p_object_owner_in || '.' || p_part_subpart_name ||
' EXCLUDING INDEXES WITHOUT VALIDATION '; *
ORA-14291: cannot EXCHANGE a composite partition with a non-partitioned table

The subpartitioning scheme of the composite partitioned table must be matched by a partitioning scheme on the temporary table.
In your case you need to list partition your temporary table on TRAN_NBR

Similar Messages

  • ORA-00385: cannot enable Very Large Memory with new buffer cache 11.2.0.2

    [oracle@bnl11237dat01][DWH11]$ sqlplus / as sysdba
    SQL*Plus: Release 11.2.0.2.0 Production on Mon Jun 20 09:19:49 2011
    Copyright (c) 1982, 2010, Oracle. All rights reserved.
    Connected to an idle instance.
    SQL> startup mount pfile=/u01/app/oracle/product/11.2.0/dbhome_1/dbs//initDWH11.ora
    ORA-00385: cannot enable Very Large Memory with new buffer cache parameters
    DWH12.__large_pool_size=16777216
    DWH11.__large_pool_size=16777216
    DWH11.__oracle_base='/u01/app/oracle'#ORACLE_BASE set from environment
    DWH12.__pga_aggregate_target=2902458368
    DWH11.__pga_aggregate_target=2902458368
    DWH12.__sga_target=4328521728
    DWH11.__sga_target=4328521728
    DWH12.__shared_io_pool_size=0
    DWH11.__shared_io_pool_size=0
    DWH12.__shared_pool_size=956301312
    DWH11.__shared_pool_size=956301312
    DWH12.__streams_pool_size=0
    DWH11.__streams_pool_size=134217728
    #*._realfree_heap_pagesize_hint=262144
    #*._use_realfree_heap=TRUE
    *.audit_file_dest='/u01/app/oracle/admin/DWH/adump'
    *.audit_trail='db'
    *.cluster_database=true
    *.compatible='11.2.0.0.0'
    *.control_files='/dborafiles/mdm_bn/dwh/oradata01/DWH/control01.ctl','/dborafiles/mdm_bn/dwh/orareco/DWH/control02.ctl'
    *.db_block_size=8192
    *.db_domain=''
    *.db_name='DWH'
    *.db_recovery_file_dest='/dborafiles/mdm_bn/dwh/orareco'
    *.db_recovery_file_dest_size=7373586432
    *.diagnostic_dest='/u01/app/oracle'
    *.dispatchers='(PROTOCOL=TCP) (SERVICE=DWH1XDB)'
    DWH12.instance_number=2
    DWH11.instance_number=1
    DWH11.local_listener='(DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=TCP)(HOST=bnl11237dat01-vip)(PORT=1521))))'
    DWH12.local_listener='(DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=TCP)(HOST=bnl11237dat02-vip)(PORT=1521))))'
    *.log_archive_dest_1='LOCATION=/dborafiles/mdm_bn/dwh/oraarch'
    *.log_archive_format='DWH_%t_%s_%r.arc'
    #*.memory_max_target=7226785792
    *.memory_target=7226785792
    *.open_cursors=1000
    *.processes=500
    *.remote_listener='LISTENERS_SCAN'
    *.remote_login_passwordfile='exclusive'
    *.sessions=555
    DWH12.thread=2
    DWH11.thread=1
    DWH12.undo_tablespace='UNDOTBS2'
    DWH11.undo_tablespace='UNDOTBS1'
    SPFILE='/dborafiles/mdm_bn/dwh/oradata01/DWH/spfileDWH1.ora' # line added by Agent
    [oracle@bnl11237dat01][DWH11]$ cat /etc/sysctl.conf
    # Kernel sysctl configuration file for Red Hat Linux
    # For binary values, 0 is disabled, 1 is enabled. See sysctl(8) and
    # sysctl.conf(5) for more details.
    # Controls IP packet forwarding
    net.ipv4.ip_forward = 0
    # Controls source route verification
    net.ipv4.conf.default.rp_filter = 1
    # Do not accept source routing
    net.ipv4.conf.default.accept_source_route = 0
    # Controls the System Request debugging functionality of the kernel
    kernel.sysrq = 0
    # Controls whether core dumps will append the PID to the core filename
    # Useful for debugging multi-threaded applications
    kernel.core_uses_pid = 1
    # Controls the use of TCP syncookies
    net.ipv4.tcp_syncookies = 1
    # Controls the maximum size of a message, in bytes
    kernel.msgmnb = 65536
    # Controls the default maxmimum size of a mesage queue
    kernel.msgmax = 65536
    # Controls the maximum shared segment size, in bytes
    kernel.shmmax = 68719476736
    # Controls the maximum number of shared memory segments, in pages
    #kernel.shmall = 4294967296
    kernel.shmall = 8250344
    # Oracle kernel parameters
    fs.aio-max-nr = 1048576
    fs.file-max = 6815744
    kernel.shmmni = 4096
    kernel.sem = 250 32000 100 128
    kernel.shmmax = 536870912
    net.ipv4.ip_local_port_range = 9000 65500
    net.core.rmem_default = 262144
    net.core.rmem_max = 4194304
    net.core.wmem_default = 262144
    net.core.wmem_max = 1048586
    net.ipv4.tcp_wmem = 262144 262144 262144
    net.ipv4.tcp_rmem = 4194304 4194304 4194304
    Please can I know how to resolve this error.

    CAUSE: User specified one or more of { db_cache_size , db_recycle_cache_size, db_keep_cache_size, db_nk_cache_size (where n is one of 2,4,8,16,32) } AND use_indirect_data_buffers is set to TRUE. This is illegal.
    ACTION: Very Large Memory can only be enabled with the old (pre-Oracle_8.2) parameters

  • Hi, i cannot publish my iWeb site with  a non mac domaine name...can anyone help please?

    hi, i cannot publish my iWeb site with  a non mac domaine name...can anyone help please?

    Hi, I have a site developed by myself usinf iWeb and as iWeb are no longer hosting teh sites in 2012 i have found another domaine. It is with Go Daddy and the domaine / name is live. I have tried to publish site using fttp but keeps coming up wih a common error message saying the info i have input is incorrect. I have tread this may be an issue if host is a windows based host???
    appreciete your help

  • ORA-01446: cannot select ROWID from view with DISTINCT, GROUP BY, etc.

    Hi,
    I have created view by joining two tables...And it is like this...
    Create view Test_Data as
    Select t.column1, t.column2, t.rowid from table1 t
    union s.column1,s.column2, s.rowid from table2 s
    with read only...
    Now I executed the following stmt...
    Select * from Test_Data where rowid = objid_ where I am passing the objid_ value...But it gave me the above error...can not I run this select stmt using the rowid ?
    Any input is highly appreciated...
    Thanks And Best Regards,
    /Dinesh...
    Hi All Again,
    I created the view in the following way...Just to check...
    CREATE VIEW my_view AS
    SELECT t.col1 col1,
    t.col2 col2,
    t.rowid objid
    FROM table1 t
    WHERE rownum < 400
    UNION
    SELECT q.col1 col1,
    q.col2 col2,
    q.rowid objid
    FROM table2 q
    WITH read only;
    Then I executed the following stmt...
    Select * from my_view where rowid = objid_
    Then I did not get that Oracle Error ORA-01446, Does anybody have any clue regarding this matter, i.e. how the use of rownum solve this prob...
    Thanks And Best Regards,
    /Dinesh...
    Edited by: user521478 on Aug 9, 2010 4:46 PM

    Check this:
    SQL> create view my_view as select rowid rd from dual;
    View created.
    SQL> select * from my_view;
    RD
    AAAACsAABAAAAGiAAA
    SQL> select * from my_view where rd = 'AAAACsAABAAAAGiAAA';
    RD
    AAAACsAABAAAAGiAAA
    SQL> So your create view statement should be:
    Create view Test_Data as
    Select t.column1, t.column2, t.rowid rd from table1 t
    union s.column1,s.column2, s.rowid from table2 s
    with read onlyThen try:
    Select * from Test_Data where rd = objid;Edited by: AP on Jul 28, 2010 2:19 AM

  • ORA-00830: cannot set statistics_level to BASIC with auto-tune SGA enabled

    Hi Experts
    I get this error message when I try to set statictics_level parameter to basic.
    Solution says to disable auto-tuning SGA. Fine, but how can I disable it? I cannot fine any system parameter similar to it.
    thanks
    Attila

    It means you need to remove SGA* parameters from your pfile and start tuning the instance manually with SHARED_POOL_SIZE and DB_CACHE_SIZE and other parameters.

  • Error ORA-01446:cannot select ROWID  - Bug?

    Hi
    I am getting an error message in SQL Developer 3.0.04.34
    Error ORA-01446:cannot select ROWID from view with DISTINCT, GROUP BY, etc.
    (you can read the full details at http://www.techonthenet.com/oracle/errors/ora01446.php )
    when I create a view containing "DISTINCT" even though it doesn't have a rowid anywhere in the select.
    Is this a bug? The view seems to function well enough but sql developer itself seems to be struggling a bit.
    I have found accounts of similarish bugs on this site from about 2007 but relating to slightly different sets of circs, but if I am asking an old and obvious question then apologies in advance.
    C

    Hi C,
    Well, the question may be old (see at least: ORA-01446 error in SQL Developer 3EA4 but I doubt it's obvious.
    The simplest cases of create view ... as for the following selects
    select distinct deptno from dept; 
    select deptno, count(*) employees from emp group by deptno;work fine in all the 2.x, 3.x releases in the object viewer data tab. Of course, running a select which includes a rowid on these views from a worksheet will fail as expected.
    In such situations a simple, reproducible test case is always nice but, at a minimum, please provide a listing of the broken code and a description of exactly how/where in SQL Developer the error occurs.
    Regards,
    Gary Graham
    SQL Developer Team

  • Error ORA-01446 when updating a versioned table with SQLDeveloper 1.5.4

    Hi,
    I have been trying out Oracle Workspace Manager to test how versioned tables might work to our advantage. My basic testing process is:
    1. Create a table
    2. Add some data rows
    3. Version enable the table
    4. Create a workspace
    5. Goto the created workspace
    6. Update a row
    7. Commit and I get the following error
    UPDATE "COMSERV"."A_OWM_TEST" SET DESCRIPTION = 'ABCDEFGHIJzzzz' WHERE ROWID = 'AAAThNAAIAAAgwqAAY'
    One error saving changes to table "COMSERV"."A_OWM_TEST":
    Row 10: ORA-01446: cannot select ROWID from view with DISTINCT, GROUP BY, etc.
    The same update works fine from SQLPlus so my question is Does SQL developer support table versioning or have I done something wrong is setting up my versioned tables?
    Any suggestions greatly appreciated.
    Thanks
    Richard Wilkinson

    hye...
    is that any view referring to that table...
    check the code on how u create that view...
    for e.g.
    CREATE OR REPLACE VIEW testview
    (id, name)
    AS
    select * from testing;
    this also will populate that ORA-01446 error.
    just a suggestion cause i also have a similar problem on ORA-01446 and i resolve it by alter the view..
    CREATE OR REPLACE VIEW testview
    (id, name)
    AS
    select id, name from testing;
    correct me if i'm worng...i'm just a newbie..
    thank you...

  • Impdp errors with ORA-01400: cannot insert NULL into

    Hi Experts,
    I have very intresting situation when I use impdp to import table back to DB.
    Environment:
    Database Server: 10.2.0.4 Enterprise
    OS: RHEL 5.5 64-bit
    We have a table and it's size is 350+ GB and so to reclaim space I want to perform expdp/impdp operation. When I following below steps:
    1) expdp table
    2) drop table
    3) impdp full table
    It works like a charm and I am able to reclaim 83% space and table size shows about 20GB.
    But when I follow below method:
    1) expdp table
    2) truncate table (To save some time not to import indexes, stats, constraints , etc)
    3) impdp table
    I get following error:
    Connected to: Oracle Database 10g Enterprise Edition Release 10.2.0.4.0 - 64bit Production
    With the Partitioning, OLAP, Data Mining and Real Application Testing options
    Master table "SYS"."SYS_IMPORT_TABLE_01" successfully loaded/unloaded
    Starting "SYS"."SYS_IMPORT_TABLE_01": sys/******** tables=<schema>.<table_name> directory=test_dir dumpfile=<table_name>_%u.dmp logfile=impdp_<table_name>.log parallel=16 CONTENT=DATA_ONLY
    Processing object type TABLE_EXPORT/TABLE/TABLE_DATA
    ORA-31693: Table data object "<schema"."table_name" failed to load/unload and is being skipped due to error:
    ORA-01400: cannot insert NULL into ("schema"."table_name"."ID")
    Job "SYS"."SYS_IMPORT_TABLE_01" completed with 1 error(s) at 16:12:28
    Please advise how to proceed further, it seems like I am hitting some sort of Bug but metalink does not show any.
    Regards,
    MS
    Edited by: user10651321 on Nov 9, 2012 4:38 PM

    expdp and impdp operations should not be executed as SYS - try SYSTEM account instead. See first Note section here - http://docs.oracle.com/cd/B19306_01/server.102/b14215/dp_import.htm#sthref243
    Pl post the complete expdp and impdp commands used, along with a description of the table for which you encounter this error.
    HTH
    Srini

  • ORA-02348: cannot create VARRAY column with embedded LOB

    Hi
    This error message I get when I try to create a table from my schema file which has a (sub-) element of type CLOB.
    In my XML document I have an element which needs to become declared a CLOB (because it's > 4000 bytes), in my Schema I define it's element node like:
    <xs:element name="MocovuState" xdb:SQLType="CLOB">
    I can register this Schema file but when I create the table, I get the error:
    ORA-02348: cannot create VARRAY column with embedded LOB
    Does anybody know how to handle this ?
    Marcel

    You need to use the xdb:storeVarrayAsTable="true" schema annotation so that unbounded elements are created at schema registration time as nested tables. Varrays can not contain CLOBs/BLOBS. Use the schema annotation xdb:SQLType="CLOB" to tell Oracle XMLDB to use CLOB storage for the element. See your schema below:
    P.S. XMLSPY is invaluable as it supports Oracle XML Schema annotations.
    <?xml version="1.0"?>
    <xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:xdb="http://xmlns.oracle.com/xdb" targetNamespace="http://www.yourregisteredschemanamespace.com" elementFormDefault="qualified" attributeFormDefault="unqualified" xdb:storeVarrayAsTable="true">
         <xs:element name="nRootNode">
              <xs:complexType>
                   <xs:all>
                        <xs:element name="nID" type="xs:long"/>
                        <xs:element name="nStringGroup" type="nStringGroup" minOccurs="0"/>
                   </xs:all>
              </xs:complexType>
         </xs:element>
         <xs:complexType name="nStringGroup">
              <xs:sequence>
                   <xs:element name="nString" type="nString" minOccurs="0" maxOccurs="unbounded"/>
              </xs:sequence>
         </xs:complexType>
         <xs:complexType name="nString" xdb:SQLType="CLOB">
              <xs:sequence>
                   <xs:element name="nValue" type="nValue" minOccurs="0" xdb:SQLType="CLOB"/>
              </xs:sequence>
              <xs:attribute name="id" type="xs:long" use="required"/>
         </xs:complexType>
         <xs:simpleType name="nValue">
              <xs:restriction base="xs:string">
                   <xs:minLength value="1"/>
              </xs:restriction>
         </xs:simpleType>
    </xs:schema>

  • Catproc.sql gives ORA-02303: cannot drop or replace a type with type or tab

    I am running catproc.sql and am seeing several of the following errors. Appreciate any insight into the problem. Thanks..
    CREATE OR REPLACE TYPE ODCIObject AS object
    ERROR at line 1:
    ORA-02303: cannot drop or replace a type with type or table dependents
    CREATE OR REPLACE TYPE ODCIObjectList AS VARRAY(32) of ODCIObject;
    ERROR at line 1:
    ORA-02303: cannot drop or replace a type with type or table dependents

    I am in the process of doing a test upgrade of Oracle E-business 11.0.3 with Oracle 8.0.6 to Oracle E-business 11.5.10.2 with Oracle 9.2.0.
    I am following the upgrade manual:
    Oracle Applications – Upgrading Oracle Applications
    Release 11i (11.5.10.2)
    Part No. B19297-01
    I have already upgraded the database from 8.0.6 to 9.2.0 using the Oracle database migration utility at the appropriate point in the instructions.
    After upgrading the database to 9.2.0 as stated in this manual, one of the of the next Oracle Application pre-upgrade tasks is to execute a script called addb920_nt.sql which in turn executes catalog.sql and catproc.sql. I am seeing these errors when catproc.sql is executed.
    I have logged an Oracle Support SR and am awaiting a response, but wanted to know if anyone had seen similar issues.
    Thanks,
    Alma

  • Any practical experience with composite partitioning range/list?

    Hi,
    I'm working on Oracle 9.2.0.4 and I plan to migrate several large range partitioned tables into range/list partitioned tables. I was wondering I anybody has some practical experience with this new feature (range/list composite partitioning) and if he encountered any bugs or "undocumented features" ?
    Thanks for any feedback
    Maurcie
    PS: I'm not looking for any documentation about how to do it, I'm just wondering if anyone has some experience in a PRODUCTIVE environment.

    You can also put the query in a parameter file so you don't have to worry about escaping characters.
    Dean

  • ORA-02303: cannot drop or replace a type with type or table dependents

    Oracle 10.2.0.3 on solaris :
    I am trying to do a
    CREATE OR REPLACE TYPE WickType_StringArray AS TABLE OF VARCHAR2(256);
    I am getting the error :
    ORA-02303: cannot drop or replace a type with type or table dependents
    I then looked for the dependencies :
    select * from dba_dependencies where name = 'WICKTYPE_STRINGARRAY' and owner='HARPER';
    (Columns below with values are delimited by pipe | )
    OWNER|NAME|TYPE|REFERENCED_OWNER|REFERENCED_NAME|REFERENCED_TYPE|REFERENCED_LINK_NAME|DEPENDENCY_TYPE
    HARPER|WICKTYPE_STRINGARRAY|TYPE|SYS|STANDARD|PACKAGE||HARD     
    What is the best way for me to proceed to get my CREATE OR REPLACE statement working ?
    Thanks

    Well you could move to 11g but I'd suggest a less drastic measure for now. Save the data, drop the table, reload the table.
    But give serious consideration to Tom Kyte's advice about object tables: Don't use them. Instead use relational tables and object views.

  • ORA-01446: cannot select ROWID from, or sample, a view with DISTINCT, GROUP

    In my data model (load from a database) there is this data control and its accessor return.
    When I drag the accessor return inside a jsf page I create a adf read only table (that has about 5000 rows), the I run the page and it works.
    Since I want to display only 20 ( or 50 or 100 is the same) rows for each page I had changed the access mode from the default value "Scrollable" to "Range Paging" and then I ve selected range size 50.
    Now if I run hte jsf page there are no data to display and if I press the small triangles to order the column or insert a word in the filter field I have the message ORA-01446: cannot select ROWID from, or sample, a view with DISTINCT, GROUP.
    I dont know how to do to solve this problem.
    Stefano

    An other thing.
    I solved this problem, maybe I dont understand the meaning of access mode and range size , since every value I choose of these 2 fields the visualization of the table doesnt change.

  • ORA-01446: cannot select ROWID from, or sample, a view with DISTINCT, GROUP BY, etc.

    Dears,
    i have this problem after i create tabular from depend on view
    ORA-01446: cannot select ROWID from, or sample, a view with DISTINCT, GROUP BY, etc.
    this a query that i use
    select
    "INVOICE_DET",
    "INVOICE_DET" INVOICE_DET_DISPLAY,
    "INVOICE_ID",
    "STORAGE_CODE",
    "ITEM_QNTY",
    "ITEM_PRICE",
    "BONS_QNTY",
    "DISC_VALUE",
    "TOT_VAL",
    "LOCATION_CODE",
    "BATCH_DET",
    "ITEM_CODE",
    "ITEM_NAME",
    "UOM_CODE",
    "UOM_NAME",
    "SIZE_CODE",
    "SIZE_NAME",
    "COLOR_CODE",
    "COLOR_NAME",
    "STOREG_BRCHAS_BATCHN",
    "EXPR_DATE",
    "PROD_DATE",
    "ITEM_DET_ID"
    from "#OWNER#"."BRCHAS_INVOICE_DET_VIEW"
    this the view i created
      CREATE OR REPLACE FORCE VIEW "RETAIL"."BRCHAS_INVOICE_DET_VIEW" ("INVOICE_DET", "INVOICE_ID", "STORAGE_CODE", "ITEM_QNTY", "ITEM_PRICE", "BONS_QNTY", "DISC_VALUE", "TOT_VAL", "LOCATION_CODE", "BATCH_DET", "ITEM_CODE", "ITEM_NAME", "UOM_CODE", "UOM_NAME", "SIZE_CODE", "SIZE_NAME", "COLOR_CODE", "COLOR_NAME", "STOREG_BRCHAS_BATCHN", "EXPR_DATE", "PROD_DATE", "ITEM_DET_ID") AS
      SELECT invoice_det, invoice_id, storage_code, item_qnty, item_price,
              bons_qnty, disc_value, tot_val, location_code, batch_det, item_code,
              item_name, uom_code, uom_name, size_code, size_name, color_code,
              color_name, storeg_brchas_batchn, expr_date, prod_date, item_det_id
         FROM (SELECT d.invoice_det, d.invoice_id, d.storage_code, d.item_qnty,
                      d.item_price, d.bons_qnty, d.disc_value, d.tot_val,
                      d.location_code, d.batch_det, i.item_code,
                      get_item_name (i.item_code) item_name, i.uom_code,
                      get_uom_desc (i.uom_code) uom_name, i.size_code,
                      get_size_name (i.size_code) size_name, i.color_code,
                      get_color_name (i.color_code) color_name,
                      dd.storeg_brchas_batchn, b.expr_date, b.prod_date,
                      i.item_det_id
                 FROM brchas_invoice_det d,
                      brchas_batch dd,
                      brchas_batch_det b,
                      item_uom_size_color i
                WHERE dd.storeg_brchas_batchinternn = b.storeg_brchas_batchinternn
                  AND d.batch_det = b.batch_det
                  AND b.item_det_id = i.item_det_id
                  AND d.batch_det IS NOT NULL
               UNION ALL
               SELECT d.invoice_det, d.invoice_id, d.storage_code, d.item_qnty,
                      d.item_price, d.bons_qnty, d.disc_value, d.tot_val,
                      d.location_code, d.batch_det, i.item_code,
                      get_item_name (i.item_code) item_name, i.uom_code,
                      get_uom_desc (i.uom_code) uom_name, i.size_code,
                      get_size_name (i.size_code) size_name, i.color_code,
                      get_color_name (i.color_code) color_name,
                      NULL storeg_brchas_batchn, NULL expr_date, NULL prod_date,
                      i.item_det_id
                 FROM brchas_invoice_det d, item_uom_size_color i
                WHERE d.item_det_id = i.item_det_id
                AND d.batch_det IS NULL) ;
      CREATE OR REPLACE TRIGGER "RETAIL"."BRCHAS_INVOICE_DET_VIEW_TRG"
    INSTEAD OF DELETE OR INSERT OR UPDATE
    ON RETAIL.BRCHAS_INVOICE_DET_VIEW
    REFERENCING NEW AS NEW OLD AS OLD
    FOR EACH ROW
    DECLARE
    V_PRICE NUMBER;
    V_BONUS_QNTY NUMBER;
    V_DISC_VAL NUMBER;
    BEGIN
      IF INSERTING THEN
          INSERT INTO BRCHAS_INVOICE_DET
          (INVOICE_DET,
          INVOICE_ID ,
          STORAGE_CODE,
          ITEM_QNTY,
          ITEM_PRICE,
          BATCH_DET,
          BONS_QNTY,
          TOT_VAL,
          LOCATION_CODE,
          DISC_VALUE,
          CREATED_USER,
          CREATED_DATE,
          ITEM_DET_ID
          VALUES
          ("BRCHAS_INVOICE_DET_SEQ".nextval,
          :NEW.INVOICE_ID ,
          :NEW.STORAGE_CODE,
          :NEW.ITEM_QNTY,
          :NEW.ITEM_PRICE,
          :NEW.BATCH_DET,
          :NEW.BONS_QNTY,
          (:NEW.ITEM_QNTY * NVL(:NEW.ITEM_PRICE,0)) - NVL(:NEW.DISC_VALUE,0),
          :NEW.LOCATION_CODE,
          :NEW.DISC_VALUE,
          nvl(v('APP_USER'),user),
          sysdate,
          :NEW.ITEM_DET_ID);
      ELSIF UPDATING THEN
            UPDATE BRCHAS_INVOICE_DET
            SET INVOICE_ID    =:NEW.INVOICE_ID,
                STORAGE_CODE  =:NEW.STORAGE_CODE,
                ITEM_QNTY     =:NEW.ITEM_QNTY,
                ITEM_PRICE    = :NEW.ITEM_PRICE,
                BATCH_DET     =:NEW.BATCH_DET,
                BONS_QNTY     = :NEW.BONS_QNTY,
                TOT_VAL       =(:NEW.ITEM_QNTY * NVL(:NEW.ITEM_PRICE,0)) - NVL(:NEW.DISC_VALUE,0),
                LOCATION_CODE =:NEW.LOCATION_CODE,
                DISC_VALUE    = :NEW.DISC_VALUE,
                ITEM_DET_ID =:NEW.ITEM_DET_ID
            WHERE INVOICE_DET =:NEW.INVOICE_DET;
      ELSE
            DELETE FROM BRCHAS_INVOICE_DET
             WHERE INVOICE_DET =:OLD.INVOICE_DET;
      END IF;
       EXCEPTION
         WHEN OTHERS THEN
           -- Consider logging the error and then re-raise
           RAISE;
    END BRCHAS_INVOICE_DET_VIEW_TRG;
    ALTER TRIGGER "RETAIL"."BRCHAS_INVOICE_DET_VIEW_TRG" ENABLE;
    please i need help
    Thanks
    Ahmed

    Hi,
    This might help
    http://www.techonthenet.com/oracle/errors/ora01446.php
    Regards,
    Jari

  • Help with circumvention of ORA-01472: cannot use connect by on view with ..

    Hi,
    Any help resolving the following would be v. helpful.
    The Aim
    Produce a hierarchical report of all users and the privileges they have via the various roles they are granted.
    The SQL
    select lpad(' ', level*2,' ')|| granted_role from (select grantee, granted_role
    from dba_role_privs
    union
    select role, granted_role
    from role_role_privs
    union
    select role, privilege
    from role_sys_privs
    union
    select 'All users', username
    from dba_users)
    start with grantee='All users'
    connect by prior granted_role = grantee;
    The error
    ORA-0147: cannot use connect by on view with DISTINCT, GROUP BY, etc.
    The database
    Oracle 8.1.7.4 (Yes I know ....)
    The Solution
    [Thanks in advance]

    What if you create a table first
    create table role_grants as
        select granted_role, grantee
           from (select grantee, granted_role
                   from dba_role_privs
                 union
                 select role, granted_role
                   from role_role_privs
                 union
                 select role, privilege
                   from role_sys_privs
                 union
                 select 'All users', username
                  from dba_users)
    Then run the hierarchical report
    select lpad(' ', level*2,' ')|| granted_role
       from role_grants
       start with grantee='All users'
       connect by prior granted_role = grantee

Maybe you are looking for

  • Mac Book pro Heats up quickly and battery drains faster

    From the time i insstalled Mavericks ive been facing extreme heat issues which causes my mac to slow down. I had the same system configuration before installing maverics and it worked perfectly but after installing maverciks it is just bad. I am post

  • Updating N95 Firmware! Some important questions

    My N95 is currently running on V20.0.013. A major improvement in update were found in V20.0.015. Now a days the latest firmware is V21.0.016. Q1. If I update my N95 to 21.0.016, then would I get all the improved features of V20.0.015 as well or shoul

  • Jdeveloper- web service- can't produce wsdl for java List

    Hi- I think this is a jdeveoper bug. It looks like the same bug as #4706306 in Jdeveloper 10g bugs. There is a workaround suggest to use additional classes in the web service. But it does not work on 11g. Details of the problem ........ I am trying t

  • 1242AG How to set a password on wireless client

    Listen I wasn't able to get these woking as a Root-Bridge & Non-Root Bridge but was able to get them to work as Root-Bridge with Wireless. Ok I'm out here in the middle of nowhere in Iraq so i say fine just put a password on the wireless client but i

  • How can I change the view size to make it my default?

    the view size is way too small with pages that I open on Firefox. I want to change the size and I want to make it my default so I don't have to click on zoom in everytime I open Firefox. Where can I change this? I have Windows Vista.