4 Replies Latest reply on Jun 13, 2019 1:26 PM by sk290691-Oracle

    Unable to Update records in Table using anonymous block

    sk290691-Oracle

      Hi Team,

       

      I have 2 pages in my Apex application and page1 and Page 2.

      In Page1- I have 2 fields which I am just saving so that I can use it in Page2 to insert completely in the table with Primary key being a sequence that I created.

       

      In Page 2: primary key is hidden(sequence),

      I have a Save Button on which I have written a anonymous block(dynamic Action--> Execute PLSQL code) to insert into the table with both Page1 and page 2 Details, which went successfully and no problem with it.

       

      But the problem is with Update button.

      I am again using anonymous block(dynamic Action--> Execute PLSQL code) to update the details on the page2. But the records are not getting updated in the database.

       

      I am using Join condition of

      Id=:P6_PRIMARY_KEY (:P6_PRIMARY_KEY is the hidden field  and Id is the database field with a sequence)

      I think I am not able to fetch the Id in the where condition.

       

      Not sure If I am missing something.

       

      Regards,

      Saikumar