
Creating Triggers in Firebird Database
![]() |
Create a trigger in your database workbench name it "Data_TrigerCreated" and the code below will automatically create a timestamp into your table. |
-CREATEDDATE
-CREATEDBY
The DDL:
/*
You can change this template in the template editor:
File | Preferences | Object Templates
Trigger:
Author : KBVILLARUBIA
Date : 03/14/2011
Purpose :
*/
begin
NEW.CREATEDDATE = 'NOW';
NEW.CREATEDBY = user;
end
SAMPLE DATA WILL BE THE FF.:
CREATEDDATE CREATEDBY
3/15/2011 6:10:59PM ADMINISTRATOR