Development notes, tips and tricks for Oracle's HTML DB

Sunday, June 27, 2004

Pre-Update trigger

A trigger that functions similar to the pre-update trigger in Oracle forms is created by creating a page process that fires On Submit-Before validations and computations:

-- This example populates the country_code field from a database table
-- based on the value passed in from the state_code field.
BEGIN
IF :P1036_STATE_CODE IS NOT NULL AND :P1036_COUNTRY_CODE IS NULL THEN
select country_code
into :P1036_COUNTRY_CODE
from ct_state_code
where state_code = :P1036_STATE_CODE;
END IF;
END;

2 Comments:

Anonymous Anonymous said...

i'm thinking of running dating site purely for the disabled



---------------
filipinaheart

9:10 PM

 
Anonymous récupération informatique said...

A really well written post, thank you for your hard work, please keep it up.

récupération informatique
The best natural wonder

11:15 AM

 

Post a Comment

<< Home