Updatable View issue

I have created a view on 10g as follows:
CREATE OR REPLACE VIEW xx_aff_vw
AS
SELECT * FROM xx_aff
UNION ALL
SELECT * FROM xx_aff_arc
In the above case both xx_aff and xx_aff_arc have same columns and there are no primary or foreign keys. Only non unique keys have been applied on the columns.
I want to update and delete on the view. I am unable to do so in the above case.
Do i need to use instead of triggers to be able to achieve the same? Do give me pointers for the same!

Here is a link for you: http://download.oracle.com/docs/cd/B19306_01/server.102/b14220/triggers.htm#sthref3252
You cannot update that view because it contains UNION ALL.

Similar Messages

  • Updatable View issues:  cannot select FOR UPDATE from view with DI

    Hi All,
    I have a simple view XY and an instead of trigger on that to insert data into one table which is used in the my view. When I do insert statement on view XY it is working fine from sql but when i used same thing with page process of " Process Row of XY Automatic Row Processing (DML) " i am getting following error. I am using APEX 3.0 . Please help me.
    ORA-20001: Error in DML: p_rowid=xxxx, p_alt_rowid=abc, p_rowid2=, p_alt_rowid2=. ORA-02014: cannot select FOR UPDATE from view with DISTINCT, GROUP BY, etc.
    Thanks

    James,
    are you already on 3.0.1.00.07 or 3.0.1.00.08? Have a look at the release notes, it says something about a bug fix for some occurrences of ORA-02014.
    Also have a look at the new substitution value/item FSP_DML_LOCK_ROW which turns locking off if you set it to FALSE. See http://www.oracle.com/technology/products/database/application_express/html/3.0.1_readme.html#CHDIDIAF and also http://download-west.oracle.com/docs/cd/B32472_01/doc/appdev.300/b32471/advnc.htm#BCGFDAIJ
    Patrick
    My APEX Blog: http://inside-apex.blogspot.com
    The ApexLib Framework: http://apexlib.sourceforge.net
    The APEX Builder Plugin: http://apexplugin.sourceforge.net/ New!

  • Issue in Invoking an Updatable View with Instead of Trigger

    Hi,
    I am trying to insert a record using Updatable View with Instead of Trigger. When i try to save the data, i get the below error:
    java.sql.SQLException: ORA-01403: no data found
    ORA-06512: at line 1
    at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:457)
    at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:405)
    at oracle.jdbc.driver.T4C8Oall.processError(T4C8Oall.java:889)
    at oracle.jdbc.driver.T4CTTIfun.receive(T4CTTIfun.java:476)
    at oracle.jdbc.driver.T4CTTIfun.doRPC(T4CTTIfun.java:204)
    at oracle.jdbc.driver.T4C8Oall.doOALL(T4C8Oall.java:540)
    at oracle.jdbc.driver.T4CCallableStatement.doOall8(T4CCallableStatement.java:213)
    at oracle.jdbc.driver.T4CCallableStatement.executeForRows(T4CCallableStatement.java:1075)
    at oracle.jdbc.driver.OracleStatement.doExecuteWithTimeout(OracleStatement.java:1466)
    at oracle.jdbc.driver.OraclePreparedStatement.executeInternal(OraclePreparedStatement.java:3752)
    at oracle.jdbc.driver.OraclePreparedStatement.executeUpdate(OraclePreparedStatement.java:3887)
    at oracle.jdbc.driver.OracleCallableStatement.executeUpdate(OracleCallableStatement.java:9323)
    at oracle.jdbc.driver.OraclePreparedStatementWrapper.executeUpdate(OraclePreparedStatementWrapper.java:1508)
    at weblogic.jdbc.wrapper.PreparedStatement.executeUpdate(PreparedStatement.java:172)
    at oracle.jbo.server.OracleSQLBuilderImpl.doEntityDML(OracleSQLBuilderImpl.java:432)
    at oracle.jbo.server.EntityImpl.doDMLWithLOBs(EntityImpl.java:8566)
    Can someone help me resolve this issue?
    Also it would be great if you can share Sample codes for Invoking an updatable view with instead of trigger on Save/commit.
    Regards,
    Jeevan

    As a trigger is executed in the db and not in your app it's really hard to help as you did not give any useful information.
    Have you read this blog http://stegemanoracle.blogspot.com/2006/03/using-updatable-views-with-adf.html ?
    Timo
    Edited by: Timo Hahn on 22.09.2011 09:15
    And my friend google also found http://technology.amis.nl/blog/1447/adf-business-components-resfresh-after-insertupdate-and-instead-of-triggers

  • FSCM via WS-RM (without PI ) - Update termination issue

    Hello experts .
    We are trying to integrate SD with FSCM ( credit management) using WS-RM (without PI).
    Details of the issue and steps followed so far.
    Ideal Scenario :
    Once we create / change a sales order ( in SD ) , the interface Creditworthinessquery_out (WS Consumer ) gets triggered (in SD) and the subsequent response CREDITWORTHINESSQUERY_IN(Provider) is triggered from FSCM (with the details of creditworthiness).Once the query response in received an notification is triggered from SD to FSCM (asynchronous service).
    After receiving the query response the functionality of credit check happens while creating / changing the sales order .
    Configuration steps followed in SOAMANAGER
    We have created end points for all the relevant service interfaces (Providers) , and also created logical ports for the respective consumers.
    During the creation of logical ports - for the consumers we used the WSDL (of the providers) as the inbound message action.
    (This has been done to all the services query , notification that are relevant in our integration).
    Current behavior / issue .
    While creating sales order the sales order is not getting saved (getting updated in the database).System allows us to complete the sales order creation process and also we get a message as sales order saved successfully. But then there is a update terminated express document that pops up. Sales order is not getting updated in the database.
    When I see the logs/traces in SOAMANAGER I see that the query out is successful , query in has the right response (in warning state though) . But no notification is being triggered ?? 
    How to overcome this update termination issue ?
    When we see the SM13 log , it points to SLD issue (LCR 010: Internal error in SLD API). why do we need a SLD without PI

    Hi  ,
    Finally we are able to solve the update termination issue . But again we are using a work around .
    Situation :
    Once we executed the VA01 transaction we were getting update termination issue . After lots of debuggung we found that system was trying to get the Business system details ( Own business system data ) . The table lcrt_clntcache had no values.
    Solution
    We inserted appropriate values in the Table LCRT_CLNTCACH (business system data ) and now it works .This is a work around we got as of now.Credit checks are happening successfully and also integration is good .
    (typically if we define business system in SLD (PI) , and run SLD_CHECK , this table gets populated , but in our case we are not using PI instead we are using WS-RM)
    But now few questions arise .
    a) Why do we need a business system in case we are not using PI ( typically we define business system and technical system in PI )  and instead using WS-RM ?
    b) Is it a good practice to update the table ( as did in workaround above )?
    c) Is this any bug and needs to be consulted with SAP ?
    Please let me know your views .
    Edited by: Vedula Adeep on Jan 16, 2012 8:42 AM

  • Updatable View as data block source - can't get to work

    I have created a simple form with one data block based on an updatable view, but it doesn't work properly after the form executes a query.
    I can use DML on this view using SQL*Plus and it works as it should.
    DML works in the form too, but only until I execute a query, after that I get the "FRM-40602: cannot insert into or update a view" error each time I try an insert, update, or delete.
    This is repeated for each runtime of the form. I have set the "query only" property to yes for the non-DMLable item from the view so that isn't part of the problem. This is an example out of "Developer Advance Forms and Reports (page 112) - Oracle Press" so it should work. There is nothing else (code, triggers, etc...) in this module besides the one data block.
    Any ideas would be appreciated.
    Thanks. Bill Brosnan.

    I have had the same issue and had to go through Oracle Support to get it working.
    First of all make sure that you have a recent patch installed (patch 9 as being the latest one available).
    Second, set in the data block the property key mode to updatable and the property primary key to yes for one item of the data block. (this is bug 1561423)
    Make sure that you only modify those columns that are updateable.
    Quite a large number of bugs have been reported on the concept of updatable views and the installation of a recent patch will most definitely get you working again.
    This functionality does work !
    Goodluck,

  • Updating Views in sql server

    Hi,
    I am trying to update a view but the result is 0 row(s) updated
    ALTER VIEW vw_AuthorizedStationeries
    AS
    SELECT StationeryID,
    CreatedOn,
    StationeryName
    FROM dbo.Stationeries
    WHERE Authorized = 1
    GO
    -----------------Update Views-------------------
    UPDATE vw_AuthorizedStationeries
    SET
    CreatedOn = GETDATE()
    WHERE
    StationeryName = 'StationThree'
    GO
    What am I doing wrong?
    I am trying to update the column 'CreatedOn' with todays date where the row is 'StationThree'.
    Is it even possible to what I am trying to do using Views?
    Thanks!

    Its possible so far as view retrieves a record which satisfies your specified condition ie 
    StationeryName = 'StationThree'
    You can check if there are records satisfying condition using below query
    SELECT COUNT(*)
    FROM dbo.Stationeries
    WHERE Authorized = 1
    AND StationeryName = 'StationThree'
    Please Mark This As Answer if it helps to solve the issue Visakh ---------------------------- http://visakhm.blogspot.com/ https://www.facebook.com/VmBlogs

  • IPad mini now terrible to use, apple support no help because warranty is up.  All cause by new ios8 update, wifi issues, many apps no longer work, apps that do work now crash regularly and sometimes take several instances and reboots to even open.

    IPad mini now terrible to use, apple support no help because warranty is up.  All cause by new ios8 update, wifi issues, many apps no longer work, apps that do work now crash regularly and sometimes take several instances and reboots to even open.

    need help uninstalling ios8 and going back to 7 where things worked please.

  • Edit the hyperlink in the alert email (Modify my alert settings, View Issue Tracking)

    is it possible to add the external hyperlink in these emails instead of the internal hyperlink? 
    in example when I get a list tracking email there are hyperlink that get sent out with these tags Modify my alert settings | View Issue Tracking | mobile view  that use the internal url //servername how can I change it to use the external
    address //internetname

    Hi Joe, check out the following links for solutions:
    http://sharepoint.stackexchange.com/questions/13216/how-to-create-custom-email-alert-template-in-sharepoint-2010
    https://social.technet.microsoft.com/forums/sharepoint/en-US/e5ebc5a7-8295-49e4-a817-c31066e1ac3d/customize-the-sharepoint-2010-email-alert
    http://www.alectang.com/blog/archive/2012/05/16/how-to-customise-sharepoint-alert-email-template.aspx
    cameron rautmann

  • Update View SM30

    Hallo Guru,
    have you ever had this problem:
    I have created an update view, but when I try to update data via SM30... well, even if I save, no data is really saved...

    No, no events...
    I have:
    1. Created a Z table
    2. Created an update view for the table
    3. Created a maintainance view for the view.
    3. goto transaction SM30
    4. I make modifications, but no data is saved...

  • Update view ( view is based on 3 tables)

    i have view based on 3 tables.
    create view view_master
    select '1' as no , name , no from a
    union all
    select '2' as no , name , no from b
    union
    select '3' as no , name , no from c
    actually i wanted to update view base table, Can i update a view view_master ?
    My question here is does oracle support view update ( view is based on 3 tables)
    Please advise ,,,

    Apart from Instead of trigger any other work around? The best way to answer that question is if you let us know:
    - your database version ( select * from v$version; )
    - give us a narrowed down example of the 'begin-situation' and the desired 'final situation'.\
    See:
    {message:id=9360002} for more details.
    MY ORACLE DBA hates tiggers .He's not the only one ;)

  • Updatable view and Read only view

    Jdev version 11.1.1.6
    1. Can we use an updatable view instead of readonly view for LOVs?
    2. In my use case, I am having a panel-tabbed component. I create Region in the first tab & create Countries in the second tab. If I use a LOV for Regions based on the read-only view, then the data created & COMMITTED in the first tab is not getting reflected in the LOV in the second tab. But, if I use an updatable view for the Region field's LOV, then the LOV works fine. But, want to know if it is fine to use an updatable view for LOVs.

    Quotation from the developer guide
    >
    Best Practice: When you need to create a read-only view object for
    data lookup, you should use the entity-based view object and deselect
    the Updatable option in the Entity Objects page of the view object
    overview editor.
    >
    >
    View objects can either be related to underlying entity objects or not. When a view
    object is related to one or more underlying entity objects the default behavior supports
    creating new rows and modifying or removing queried rows. However, the update
    feature can be disabled by deselecting Updatable in the overview editor for the
    entity-based view object
    >
    So the answer for your first question is Yes

  • Viewing issues with Adobe Acrobat Professional 8

    We have Adobe Acrobat Professional 8 installed, and we are having some issues when viewing pdf documents.  Once a Word document is converted to a pdf document, some of the hyperlinks are appearing thicker (almost bold) than others, and some of the text appears lighter/darker than the rest of the text.  There is no pattern to this, it is all very random.
    When we print the pdf document, everything looks correct, so this only happening when we view the document on the computer.
    Can anyone provide a suggestion on how to fix this issue?
    Thanks!

    Sorry, I forgot the attachment!
    Hi Bill,
    I am attaching screen shots of 1) a page where the hyperlinks appear thicker and 2) the document properties pages showing the fonts.
    We have tried creating it with both the Adobe PDF Maker and the MS PDF tool and it happens using both.  I am thinking that this really is a viewing issue, because it prints out fine.  Also, it looks the same no matter what the zoom setting is.
    Please let me know if you have any other advice.
    Thank you!
    Cari

  • Muse update installation issues

    I have a monthly subscription to Muse and everytime I try to install the latest updates Ihave issues. When I try to install directly from MUSE it tells me to check my network connection - which is always fine. I have tried pausing my virus protection etc. I then try to get help from customer support and the fxes do not appear to work etiher. I haveuninstalled and reinstalled etc with no luck -any suggestions

    Try disabling any firewall or antivirus application and re-try updating, also try a different network connection. If that doesn't help, please uninstall and use the following direct download links to install Muse fresh.
    Mac - http://www.adobe.com/go/muse_latest_win
    Win - http://www.adobe.com/go/muse_latest_mac
    Thanks,
    Vinayak

  • Updatable view vs Bulk Collect

    Hi friends.
    I need to know what is more fast....
    1. SELECT RO.NR_ORDEM BULK COLLECT INTO R
    FROM REP_ORD RO, REP_TRAB RT
    WHERE RO.NR_ORDEM = RT.NR_ORDEM ;
    FORALL I IN 1..R.COUNT
    DELETE REP_ORD WHERE NR_ORDEM = R(I);
    FORALL I IN 1..R.COUNT
    DELETE REP_TRAB WHERE NR_ORDEM = R(I);
    or
    2. To create an updatable view using something like the above select. After that, to delete data from view.
    Thank you for your patient.
    Message was edited by:
    Paulinha

    I think the bulk collect approach would be certainly be easier to implement. As someone pointed out, you can't delete from a view that has a table join - directly. However, you can create an "instead of" trigger to run a short PL/SQL program instead of deleting from the view, though, in chich you would then put your delete statements. The net effect of this would be that you were back where you started with the overhead of using a view as well (though this would probably not add too much extra processing).
    Getting back to your original question, I'd guess the bulk collects would be faster provided you don't have too many items in your collections. The only way to be certain would be to do it both ways and time it.

  • UPDATABLE VIEW AND MERGE

    Good Morning
    Is it possible to use merge with an updatable view.
    I've been trying with no success.
    If it is has anyone got an example
    I've been trying things like
    merge into UPDATABLE_VIEW
    using (select '10558630',99,'dhills',sysdate from dual) ver
    on (UPDATABLE_VIEW.person_code = '10558630')
    when matched then UPDATE set UPDATABLE_VIEW.value1 = 99
    when not matched then insert values ('10558630',99,'dhills',sysdate)
    Thanks
    David

    Never tried. Post Oracle version, proper example and error(s) encountered.

Maybe you are looking for

  • HDV print to tape? Help.

    I can't seem to get my HDV sequence to print to tape. I am new to the whole HDV thing so bear with me. I am using a sony HVR-V1U. Sequence Settings: Frame size: 1440x1080 Pixel Aspect Ratio: HD 1440 x 1080 Editing Time Base: 29.97 (can't Change) QT v

  • FI Document - Open Items

    Hi All, While trying to archive the FI Documents present in our system, a huge percentage of them are not getting archived inspite of meeting the retention/residence time requirements. The spool says these docs have open line items. My query is: how

  • Window Size in Time Machine

    Does anyone know how to set a custom window size for the Finder window when entering Time Machine? Whenever I enter Time Machine, the Finder window is resized and it gets really annoying. I know how to resize it when I'm in Time Machine, but I want t

  • Cannot acess classes in the same package.

    Hi I have "a.java" in c:/java/test directory. I have "b.java" file in the same directoty which creates a instance of "a" class. "a.java" compiled fine. But when compliling "b.java" i get error message cannot resolve symbol symbol : class a I have use

  • Cristal report Related

    Hi Can I marge the cristal report with the apex. if we can what the procedure or steps we have to follow. I want to use the cristal report to create the bills. Thanks & Regards Nisha