A friendly place for programming greenhorns!
Big Moose Saloon
Register / Login
Win a copy of
Spring in Action
this week in the
Help me in creating a Trigger for Insert and Update Options
Ravi Kiran Va
Joined: Apr 18, 2009
Jan 07, 2010 10:53:12
Please help me in creating a Trigger .
My requirement is that after insert or update on a Table , i want to fire an event .
I have started this way ,but doesn't know how to fully implement this .
say i have a dept table
CREATE TRIGGER DepartmentTrigger
AFTER INSERT ON Dept
INSERT INTO mytable VALUES("123","Kiran");
Please tell me how can i put the Update option also .
Thanks in advance .
Save India From Corruption - Anna Hazare.
author & internet detective
Joined: May 26, 2003
Jan 07, 2010 18:53:54
You add it to the "after" clause on the trigger. See the
full syntax for triggers
How To Ask Questions The Smart Way
Blogging on Certs:
SCEA Part 1
Part 2 & 3
Core Spring 3
TOGAF part 1
It is sorta covered in the
JavaRanch Style Guide
subject: Help me in creating a Trigger for Insert and Update Options
Need to Invoke a Java Program from a trigger
Need to call a Java Object / Servlet from a Trigger
A doubt with triggers
Trigger Function Problem
Issue in Inserting / Updating the table with trigger using Hibernate
All times are in JavaRanch time: GMT-6 in summer, GMT-7 in winter
| Powered by
Copyright © 1998-2014