Automatic Row Processing and Casade Delete

I have Automatic Row Processing for delete on a table, however I have FK's dependent on this table. How do I do a cascade delete using Automatic Row Processing DML for a delete ?
Any way besides writing a trigger ?

My fault, my constraint was not written properly to indicate on delete cascade.

Similar Messages

  • Bug Report: Automatic Row Fetch/Automatic Row Processing and invalid column

    Hi,
    if an invalid column name is specified for a page item of type "Database Column", no error is reported by the Automatic Row Fetch/Automatic Row Processing process. It's just ignored and nothing is returned!!! That makes it kind of hard to identify such an error.
    The problem can happen for example when a column is renamed or if there is a typo in the column name during creation.
    The problem seems to be related to the following query which doesn't use an outer join.
    SELECT C.COLUMN_NAME, C.DATA_TYPE, I.NAME, I.FORMAT_MASK, I.DISPLAY_AS
    FROM
    SYS.ALL_TAB_COLUMNS C, WWV_FLOW_STEP_ITEMS I WHERE C.OWNER = :B4 AND
      C.TABLE_NAME = :B3 AND I.SOURCE = C.COLUMN_NAME AND I.SOURCE_TYPE =
      'DB_COLUMN' AND I.FLOW_ID = :B2 AND I.FLOW_STEP_ID = :B1 AND (C.DATA_TYPE
      IN ('DATE','NUMBER','CLOB','LONG','FLOAT') OR C.DATA_TYPE LIKE 'NUMBER%' OR
      C.DATA_TYPE = 'CHAR' OR C.DATA_TYPE LIKE '%VARCHAR%' OR C.DATA_TYPE LIKE
      'TIMESTAMP%') ORDER BY C.COLUMN_IDBTW, if an invalid table/view name is specified for a Automatic Row Fetch/Automatic Row Processing process, the error message during runtime isn't very speaking.
    ORA-06550: line 1, column 17: PL/SQL: ORA-00936: missing expression ORA-06550: line 1, column 9: PL/SQL: SQL Statement ignoredMaybe that could be changed too.
    Thanks
    Patrick
    My APEX Blog: http://www.inside-oracle-apex.com
    The APEX Builder Plugin: http://builderplugin.oracleapex.info/
    The ApexLib Framework: http://apexlib.sourceforge.net/

    It says filed (with an L) not fixed (with an X). That means they have noted down the bug, but it may or may not have been fixed yet.

  • Automatic row processing in a validation

    Hi,
    I have a form on a table (page11) with one process for automatic row processing and I have the buttons Submit and Create.
    I have another button f.e. BUTTON_NEW. I have a validation (function returning error text) with "BUTTON_NEW" as When-Button-pressed-Condition. In the validation I did an Insert into another table.
    I changed values of items on Page11 and don't press Submit. And then I press "BUTTON_NEW". The validation on BUTTON_NEW works fine. But the changed values are lost. Is there a possibility for an automatic "Submit" or "Create" when BUTTON_NEW is pressed?
    Thanks, Daniela

    Hi,
    these are the values I currently see:
    108 14 P14_SELECTEDSS Display as Text (escape special characters, does not save state) No
    108 14 P14_CHARACTERISTIC_ID Hidden and Protected Reset to Null No
    108 14 P14_SHAREDSERVICE_ID Text Field 30 Inserted No
    108 14 P14_CAPTION Text Field No
    108 14 P14_CATEGORY_ID Select List No
    108 14 P14_WEIGHING Text Field No
    108 14 P14_DESCRIPTION Textarea No
    I also have to say that I deleted the computations I created earlier again cause they did not work and I had the same values for these variables. I am trying to (pre)set P14_SHAREDSEVICE_ID to P13_SELSS when I click the create button on page 13.
    Thanks again,
    Henrik

  • Automatic Row Processing?

    Hi,
    I have a requirement to create forms that insert into multiple tables and returns items from multiple tables. What are my options? Can I still use automatic row processing and fetching?
    Thanks in advance.

    create multiple regiions embedded with different table

  • Automatic ROW Processing error after changing Schema

    Hello all,
    I have an APEX 3.0 application referencing tables on a different schema from the parsing schema.
    Workspace A -> using parsing schema A1
    Application A -> installed in Workspace A
    Application A -> access tables in schema A2 from schema A1, through synonyms
    All is working fine.
    Then I had to duplicate the application (let me say: to have a test environment).
    So, I created a Workspace B, a parsing schema B1, I've installed application A as application B in workspace B, and I've created schema B2 and I gave the grants to schema B1.
    Application B is running fine when trying to access objects on the parsing schema B1, but it returns a lot of errors when accessing objects on schema B2, in particular on Automatic Row Processing and Automated Row Fetch processes. The error I'm getting vary from ORA-942 (table or view doesn't exist) to ORA-936 (missing expression).
    A strange thing is that in Automatic Row Processing and Automated Row Fetch processes, I can choose only schema A1 as Table Owner, and all is working fine.
    In application B, I can select as Table Owner also the schema B2, even if it's not associated to the workspace. By doing this something works better. But I don't want to modify every page in the application where this happens. Also because I want the opportunity to maintain only one application.
    I think that the application installed in workspace B, still tries to access objects in schema A2, but I don't know why.
    Do you have any suggestion?
    Thanks.
    Andrea

    It returns these results:
    WORKSPACE     APPLICATION_ID     APPLICATION_NAME     PAGE_ID     PROCESS_SOURCE
    WS_DEMO     107     myappname     73160     F|&FETCH_SCHEMA.:CDW_LST_GRP:P73160_LTG_ID:LTG_ID
    WS_DEMO     107     myappname     73160     &FETCH_SCHEMA.:CDW_LST_GRP:P73160_LTG_ID:LTG_ID|IUD
    The query returns the same results in PROCESS_SOURCE columns, when ran from workspace A or B.
    I've found that FETCH_SCHEMA is an "application definition", and I've setup correctly in workspace B. The problem persists.
    Bye,
    Andrea

  • Solved: Delete Using Automatic Row Processing

    See Scott's reply below for the answer.
    Hi there,
    I have an application built in APEX 3.0.1 that I would like to be able to use a button to delete a single row from an underlying database table (owned by the parsing schema).
    My APEX page has a 3 HTML regions on it:
    1. Only a Select List and Go button for User selection (of Debit Note)
    2. Ten display Items (Text Field, Disabled saves state) displaying further information about User selection
    3. Conditional Delete button (region with custom image) - only displays when P73_DEBITNOTEID is NOT NULL
    I'd like this button to be used to Delete the Selected Item and thought I'd be able to use a Data Manipulation Page Process - Automatic Row Processing (DML) page process to do this.
    However, when I go through the wizard the Select item containing primary key column value field has no values in the search list.
    My first question is why was there no values in the list?
    So I manually entered the Item I required (P73_DEBITNOTEID) but when I run the page and click the button I get a PL/SQL missing expression error.
    What is the best practice method to do DML actions on the underlying database tables. The tables are all owned by the parsing schema.
    Your help in resolving this matter would be greatly appreciated.
    Kind Regards,
    Gary.

    Gary,
    The DML processes (and the creation wizards for them) are for use with items having source type Database Column. If your page items don't use this source type, then neither the Automated Row Fetch nor the Automatic Row Processesing (DML) process types will work.
    Scott

  • Page having PL/SQL process and Automatic Row Process for 2 different tables

    Hi,
    I have a page containing 2 regions A & B.
    Region-A content would be updated to table T1(PK : Ticket#).
    Region-B content would be inserted into table T2(PK: Attachment# ; FK: Ticket#).
    Region-B is used for uploading a file content into T2.
    Since I cannot use 2 DML processes on the page for 2 different tables with a common column, so I have a PL/SQL process to update the record into T1 and an Automatic Row Process(DML) for inserting into T2.
    Now the issue is in Region-B when I select a file using 'Browse' button and click on Upload button to fire the Automatic Row Process, the success message is displayed but the file is not uploaded into the table. But when I moved the entire Region-B and the Automatic Row Process to a different page and clicking Upload is working fine and inserting the record into the table along with the file content.
    An item P10_TICKET_NUMBER with source type as Database column with source value as TICKET_NUMBER is used in Region-A.
    I have gone through the forums and found some of the threads below
    Re: 2 Automated Row Processes for one page?
    Re: Error when trying to create 2 Forms on same page on 2 tables with ID as
    where people facing similar issues but here I have followed the solution provided(with one PL/SQL process and other Automatic process) in the threads but still issue persists.
    Can anyone throw some light on this please.
    Thanks,
    Raj.

    Hi Teku,
    You just have a look at this thread, where u can find a solution for your problem.
    INSERTING Records into Second table based on First table Primary Key
    hope this helps.
    Bye,
    Srikavi

  • Without Automatic Row Processing (DML)

    Hi All
    I try to make one page to show use DML statements without standard Automatic Row Process.
    What I have:
    One page with:
    region: Report - select empno, ename, sal, deptno from emp;
    region: Form with items: p6_empn, p6_ename, p6_sal, p6_deptno
    addictionaly in that moment I have:
    process CreateProcess:
    begin
    insert into emp (empno, ename, sal, deptno)
    values (emp_seq.nextval, :P6_ENAME, :P6_SAL, :P6_DEPTNO);
    commit;
    end;
    and button CREATE.
    Create Process is fired when I push CREATE button and Insert statement works corecctly. Branch is on the same page. (I use request).
    Now I would like to show update and delete statements.
    In Report I have in column EMPNO standard button Edit (each row)
    (<img src="#IMAGE_PREFIX#edit.gif" alt="Edit">)
    I have process SelectProcess:
    begin
    select ename,sal,deptno
    into :p6_ename, :p6_sal, :p6_deptno
    from emp
    where empno = :p6_empno;
    end;
    It is fired In Load _ Before Header
    When I push Edit in one row I would like to see details of employee in Form, but I see nothing. In session state all is correct - I see :p6.... with name, sal and ...
    I dont know how to connect this process with buton and branch.
    could you help me?

    Hi,
    I have done a quick test for this - [http://htmldb.oracle.com/pls/otn/f?p=25946:1]
    On the Edit page, I have a process called P2_LOAD_DATA that runs "On Load - Before Header", is conditional on P2_EMPNO being NOT NULL and using the following code:
    BEGIN
    SELECT EMPNO, ENAME, JOB
    INTO :P2_EMPNO, :P2_ENAME, :P2_JOB
    FROM EMP
    WHERE EMPNO = :P2_EMPNO;
    END;I have a button with a Button Name setting of "UPDATE" (user sees this as Apply Changes)
    I then have a process that runs "On Submit - After Computations and Validations" and is conditional on REQUEST = UPDATE. The code is:
    BEGIN
    UPDATE EMP
    SET ENAME = :P2_ENAME,
    JOB = :P2_JOB
    WHERE EMPNO = :P2_EMPNO;
    END;The source settings on P2_EMPNO, P2_ENAME and P2_JOB are as I described in my previous post.
    One thing to check - do you have a "reset page" process? If so, remove it.
    Andy

  • Adding a new field to an Automatic Row Processing form

    Hi,
    I have a form that I built through the form Wizard which has an automatic row processing function. It is working very well, except that any new fields I add to the form are not being updated in the database when the row is processed. I have set up the field exactly the same as other fields which are working and were originaly created by the wizard. I have deleted and recreated the row processing Page Process, but nothing seems to make it work. Have I missed anything? I don't want to recreate my page from scratch each time I want to add a new field.
    Thanks,
    Steve

    if you're positive that your new fields/columns update correctly when you use Text Field items and not when you use Select List ones, i'd check to see what your select lists are returning. a good way to see exactly what your form got from your select list items is to check the session state for your select list items right after you submit your page (clicking the "Session" link in your developer toolbar in your runtime environment is a good way to get to this info). also, even though you said your added Text Fields work and your Select Lists don't, i'd still check the "Source Type" and "Source value or expression" fields of your select list items to make sure they're set correctly. for form items to work with your table in htmldb auto-dml processing, you need to set the "Source Type" to "Database Column" and the "Source value or expression" to the case-sensitive name of your db column.
    hope this helps,
    raj

  • Automatic row fetch and items initialization

    Hi team,
    I was modifying a page and I came across the following situation:
    I had a form with MRU processing and automatic row fetch and I wanted to make SAVE and DELETE buttons conditional basing on a certain flag contained in the row being read.
    The flag is read into a hidden item having sequence number lower than any button, however I found out that the condition could not be reliably tested as the value in the session state was coming from a previous visit to the page. Some times the buttons were there, some not, at the beginning it was puzzling.
    So, I added a computation based on a SQL query where the hidden flag was computed before the header, basing on the primary key being passed from the calling page and the problem was gone, but for some reason I didn't feel satisfied, it was too cumbersome.
    I thought session state items would be assigned beforehand, but for some reason it looked like they were assigned at a later time, even if the automatic fetch process is supposed to run before the header.
    Then I noticed an "innocent" option in the fetch process definition saying "set memory cache on Fetch / set memory cache on Display".
    In my case was checked the former, but as soon as I checked the latter, I could remove the unnecessary SQL query computation.
    So, I started off posting a problem and ended up with the solution...
    Bye,
    Flavio

    Flavio,
    Thanks for the testimonial. That feature (new in 1.6) is for the very situation you described. When you create new row fetch processes they will have the "set memory cache on Fetch" option selected by default. For existing processes, the option must be manually changed.
    Scott

  • Automatic row processing insert fail

    Hi all,
    Application Express 3.2.1.00.11
    Oracle Database 10g Release 10.2.0.3.0 - 64bit Production
    I am running into a problem where my automatic row processing will update and delete records but will not insert. I get the following error.
    ORA-44003: invalid SQL nameI disabled all triggers and added the appropriate fields to my form and manually entered correct data and am still having the issue. I can run a trace but only the dba has access to retrieve the file and he is gone. Any suggestions on where to start? i checked debug mode and it is definitely hanging on the ARP.
    Cheers,
    Tyson Jouglet

    All,
    Finally fixed it!!! So if you experience this problem, double check all of your item sources. I was upgrading a date column to a timezone column and subsecuently made it three different items. Long story less long, I left the original date item on the form and deleted the source column name but i forgot to change the item source from database column to something else. This will not effect how apex deletes or updates a record but it will not allow you to insert a new record. I know this is a user error, but maybe this could be added as a validation?
    Cheers,
    Tyson Jouglet

  • Automatic Row Processing - Preset a value with value from other page

    Hi everybody,
    I have created a form on a table with report. I added a dropdown field to a sidebar region on the first page the groups and selects only a couple of these entries. (Think: only people for the department selected in the drop down field). Now when I click on the normal create button the id field for the department should be filled automatically with the value from the page before, where something was already selected in the drop down field. The id field is a hidden field on the actual create page. Maybe it is not working because the field is linked to the database column to make the automatic row processing work or something. I tried computions on both pages and setting the values. Nothing seems to do the trick.
    Any help would be greatly appreciated.
    Thanks,
    Henrik

    Hi,
    these are the values I currently see:
    108 14 P14_SELECTEDSS Display as Text (escape special characters, does not save state) No
    108 14 P14_CHARACTERISTIC_ID Hidden and Protected Reset to Null No
    108 14 P14_SHAREDSERVICE_ID Text Field 30 Inserted No
    108 14 P14_CAPTION Text Field No
    108 14 P14_CATEGORY_ID Select List No
    108 14 P14_WEIGHING Text Field No
    108 14 P14_DESCRIPTION Textarea No
    I also have to say that I deleted the computations I created earlier again cause they did not work and I had the same values for these variables. I am trying to (pre)set P14_SHAREDSEVICE_ID to P13_SELSS when I click the create button on page 13.
    Thanks again,
    Henrik

  • Automatic Row Processing (DML) - Return Key Into Item

    Hello,
    This question is on Apex 4.2:
    I'm Displaying the [UNIKEY] column value after the record is inserted into the table using :
    page process > process row table_name > Source: Automatic Row Processing (DML) > Return Key Into Item > "Item Name"
    This works fine while inserting records, my question is why this does not respond on update / delete ?
    ϯ LT

    LT
    Check your branches.
    What might be happening is that on insert and update an other branch is followed.
    Where the branch of the insert either isn't clearing the cache of the page or is setting the item with it's own value.
    The branch on the update on the other hand is clearing the cache of the page and not setting the item.
    With a delete there is a clear cache process generate by the wizard. Check if this process is only running on the delete and not on the update.
    From memory the process is called something with reset.
    If the above doesn't help try to replicate the problem on apex.oracle.com and give access with a guest developer account so we can have a look.
    Nicolette

  • Automatic Row Processing BUG?

    Unfortunately it turns out that one can not create report with form through the wizard if the target table has a primary key that should be updatable. Is that true?
    I have a table with only 2 columns 1-code of some type, 2-description. Column 1 is primary key.
    I get the following error when I try to change tha value of column 1:
    ORA-20001: Error in DML: p_rowid=ass, p_alt_rowid=CURRENCYCODE, p_rowid2=, p_alt_rowid2=. ORA-01403: no data found
    I searched through the forum but noone explained why this happens. And the only thing that I think is the reason for this is that Automatic Row Processing does not remember the previous value of the primary key column so its embedded SET statement only has the new value.
    Is this a bug?
    I don't want to create different processes to update, delete, create. This however involves using temp hidden field to hold the original value of my first column.
    Would You fix this to be done automatically in HTMLDB when using the wizard with Automatic Row Processing?
    My version is: 1.6.0.00.87
    Thanks

    Well, actually the wizard succeded but it did not do what I needed: my table is with one column (primary key) and another column (varchar). The wizard asked me for my primary key column and I pointed it, but after it secceeded and I ran the form, the field was hidden. But I wanted it to be avalable for entering/editing so I changed it to a text box type. Does that help?
    And another thing what happens if I use the wizzard on a table with to columns which define a composite primary key. when i point them on the relevant page, the next page of the wizzard asks me to choose columns, but there aren't any more because it appears to hide my primary key fields. In this case i really can not use the usard for helping me with automatic processing. This and the previous case I believe are if not bugs then at least "lacks" of the wizzard.

  • Automatic Row Processing (DML) Update problem

    Hi All,
    I am using Oracle 10.2.0.3 on Windows Server 2003 with "Application Express 3.1.0.00.32".
    I have two schemas in the database, A and B
    B has all the tables which holds the production data
    A has all the synonymns for all of B's objects and plus insert, delete, update, execute rights on B's objects.
    I have a view MyView which basically reads from a table from B's schema
    and an APEX form based on this view... so far so good.
    Problem is when I generate a form using form wizard and try to update a record in the table in B's schema, I get the following error: I cannot use B as the OWNER in APEX, because for other reasons, I need to use A.
    Automatic Row Processing (DML)
    ORA-20505: Error in DML: p_rowid=CA-4837-AHU-002, p_alt_rowid=OBJ_CODE, p_rowid2=, p_alt_rowid2=. ORA-20503: Current version of data in database has changed since user initiated update process. current checksum = "97813992F558009979B5B86C925AD4AC" application checksum = "FA8AB5EC759780B0048E2C11584CD5E6"
    Does anybody know why I get this error message? Is it possible to update the table using the view? I know for sure that my browser is not caching the data and someone else is not editing the same record.
    Thanks in advance,
    Sinan

    Hi,
    Problem is when I generate a form using form wizard and try to update a record in the table in B's schema, I get the following error: *I cannot use B as the OWNER in APEX*, because for other reasons, I need to use A.As highlighted, you need to grant insert, delete, update, execute rights on B schema's objects to APEX schema. Also, you may need to use "Instead of" trigger for view.
    Regards,
    Mangal

Maybe you are looking for

  • ABAP (Routine) Error in BW Transformations

    Hi Experts, As i am new(Learner) to BW Please advise me on how can i achieve this and update me with Releavent Start Routine and Field Routine....please My Requirment is Employee is Compounded on Location. On Weekly or Monthly basis (dependending on

  • Trying to move files to /usr/bin

    I am trying to install g77 on my Powerbook, but I keep getting a "permission denied" when I try to move the files to /usr/bin so I can link them to gcc. I have admin permissions, but it still won't let me put the files I need in the /usr/bin director

  • PDF's won't open in browsers anymore

    Hi I had some updates for my Macbook Pro (snow leopard- up to date) and for some reason now I can't open pdfs on the web on either safari or firefox. If I download them it works, but I can't view them on the acutal browser anymore. When I open a webs

  • Attaching a new Robohelp Template in the toolbar

    I m unable to attach the Robohelp Template in the Toolbar. can you please help me with it. I tried creating a macro, re-installing word, re-installing robohelp. It is still not able create the toolbar.

  • KDE Very Slow - But only on Wifi

    Hi all, I've a strange issue.  I've installed Arch and KDE on a Thinkpad T61 and it all works wonderfully, except that KDE freezes when using the widgets or toolbar when I'm on a wifi network.  If I'm on a wired network it's fine.  An example is that