|
 |
|
Oracle Tips by Burleson |
Examining APEX's Buttons
These buttons are special because they have the
Database Action attribute set to a particular setting corresponding to
their participation in the Automatic Row Processing process. It would
be advantageous to navigate to the button attributes page as a
reference while viewing the following description of the button
attributes.
The conditional display on the buttons is based on
the P12_ID page item. The idea is if there is a value in the P12_ID
item, then the record exists and can therefore be UPDATEd or DELETEd.
If the P12_ID item is NULL, no record exists and therefore the record
needs an INSERT action.
DELETE button
Table 8.1 shows the important attributes of the
Delete button.
|
Database Action |
SQL DELETE action |
|
Conditional display |
When P12_ID is NOT NULL. |
|
Optional URL Redirect |
The Delete button also has the special
function of asking the user if they are sure they want to delete
the record before actually performing the delete. This is done by
using the Optional URL Redirect attributes of the delete button. |
SAVE button
Table 8.2 shows the important attributes of the
Save button.
|
Database Action |
SQL UPDATE action |
|
Conditional display |
When P12_ID is NOT NULL. |
CREATE button
Table 8.3 shows the important attributes for the
Create button.
|
Database Action |
SQL INSERT action |
|
Conditional display |
When P12_ID is NULL. |
Table 8.3:
Create button attributes.
The above book excerpt is from:
Easy HTML-DB
Oracle Application Express
Create
Dynamic Web Pages with OAE
ISBN 0-9761573-1-4
Michael Cunningham & Kent Crotty
http://www.rampant-books.com/book_2005_2_html_db.htm |