11.01.2013 Views

Oracle Forms Developer – Form Builder Reference, Volume 1

Oracle Forms Developer – Form Builder Reference, Volume 1

Oracle Forms Developer – Form Builder Reference, Volume 1

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

48<br />

IF :System.<strong>Form</strong>_Status ’QUERY’ THEN<br />

Message(’An error prevented your changes from being<br />

committed.’);<br />

Bell;<br />

RAISE <strong>Form</strong>_trigger_Failure;<br />

END IF;<br />

END IF;<br />

END;<br />

Example 2<br />

/*<br />

** Built-in: COMMIT_FORM<br />

** Example: Perform <strong>Form</strong> <strong>Builder</strong> database commit during commit<br />

** processing. Decide whether to use this Built-in<br />

** or a user exit based on a global flag setup at<br />

** startup by the form, perhaps based on a<br />

**<br />

** trigger: On-Commit<br />

*/<br />

BEGIN<br />

/*<br />

** Check the global flag we set during form startup<br />

*/<br />

IF :Global.Using_Transactional_Triggers = ’TRUE’ THEN<br />

User_Exit(’my_commit’);<br />

/*<br />

** Otherwise, do the right thing.<br />

*/<br />

ELSE<br />

Commit_<strong>Form</strong>;<br />

END IF;<br />

END;

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!