When a page is submitted in APEX, can you describe any way of making the record update conditional on a Yes/No confirmation box, with the opposite choice running a custom SQL statement:
1. user clicks Save
2. prompt user to confirm save
a. if saved then, update record as per standard Automatic Row Processing (DML)
b. if not saved then, "UPDATE ACTIVITY_REQUESTS SET STATUS = :P14_STATUS"
(Alternative ways of achieving the same outcome gladly considered)
If you could help me out with a better understanding of buttons that would be great. These four questions give expression to one 'hole' in my understanding.
Q1) The help given under 'Database Action' in 'Edit Page Buttons' on an APEX form states - "If I do not set this attribute, database processing will execute based on the button name. The button name determines the value of he built-in attribute REQUEST." - what does this mean? can I specify a PL/SQL script somewhere?
Q2) I have created some Processes with ('On Submit - After Computations and Validations'). I have a working knowledge of these, but I don't understand how APEX knows when / which process to run when a button is clicked.
Q3) how do the tags 'DELETE' and 'SAVE' (i.e. see following example) tell APEX which processes / updates / deletions to run?
Q4) I have a funny bug in which I click delete, and the save action is processed.
i) The Delete button 'Action' is 'Redirect to URL' =
this throws up the expected message box, but the record is never deleted - instead various processes run which are only meant to run when the record is saved.
ii) the SAVE button Action is 'Defined by Dynamic Action' with '- No Database Action'. The dynamic action either updates the field 'Status' or saves the entire record using the following java command: