Results 1 to 4 of 4
Thread: What is trigger?
-
05-12-2011, 06:41 AM #1
What is trigger?
I know that A trigger is a special kind of stored procedure that is invoked whenever an attempt is made to modify the data in the table it protects. Modifications to the table are made ussing INSERT,UPDATE,OR DELETE statements.
For example, if you have a table with a field that contains the date this record has been modified, you could set a trigger on updates and inserts that will set this field to the current date so you wont have to handle this field in your application code.
Triggers are used to enforce data integrity and business rules such as automatically updating summary data. It allows to perform cascading delete or update operations. If constraints exist on the trigger table,they are checked prior to the trigger execution. If constraints are violated statement will not be executed and trigger will not run.Triggers are associated with tables and they are automatic . Triggers are automatically invoked by SQL SERVER. Triggers prevent incorrect , unauthorized,or inconsistent changes to data.
-
05-12-2011, 10:08 AM #2
Sophomore
- Join Date
- Apr 2011
- Posts
- 79
- Thanks
- 0
- Thanked 2 Times in 2 Posts
- Feedback Score
- 0
Triggers are programs that execute in acknowledgment to changes in table abstracts or assertive database events. There is a predefined set of contest that can be "hooked" with a trigger, enabling you to accommodate your own processing with that of the database.
-
04-03-2012, 02:52 AM #3
Sophomore
- Join Date
- Mar 2012
- Posts
- 144
- Thanks
- 0
- Thanked 0 Times in 0 Posts
- Feedback Score
- 0
Triggers are the programs that is used to store the procedure.. Trigger is part of mysql...
-
04-16-2012, 08:55 AM #4
Freshman
- Join Date
- Apr 2012
- Location
- New York
- Posts
- 18
- Thanks
- 0
- Thanked 0 Times in 0 Posts
- Feedback Score
- 0
Trigger is a SQL procedure that initiates an action, when an event (INSERT, DELETE or UPDATE) occurs.



Reply With Quote

