Over a year ago I wrote an article covering how to create a tabular form and then use custom PL/SQL to process the data rather than the automatic Apply MRU and Apply MRD processes. The demo showed how to do this in APEX 4.2. This article will re-introduce the topic but use APEX 5.0 instead.
Create new Tabular Form
- Create page > Page type: Form > Tabular Form
Select the following options:
Note: For simplicity/demo purposes, limiting to just the
SAL
andENAME
columns.* Primary Key: Select Primary Key Column(s) > Primary Key Column 1 >EMPNO
- Run through the rest of the wizard.
Remove Automatic DML
Since custom code will be used to process the page, delete the automatic row processing process as shown below.
Create Process
Create a new process with the following settings (the Source is included below the image).
if :empno is null then
-- code to insert emp
null;
else
update emp
set
ename = :ename,
sal = :sal
where empno = :empno;
end if;
Using the above technique you can now use a tabular form to call custom PL/SQL code rather than the automatic row processing.
The next article will cover how to modify data from multiple tables in the same Tabular Form.