C# Tutorials and offshore development in India
    Tutorials   Resources   Forum   Reviews   Communities   Interview   Jobs   Projects   Training   Your Ad Here    
Silverlight Games | Mentor | Code Converter | Articles | Code Factory | Computer Jokes | Members | Peer Appraisal | IT Companies | Bookmarks | Polls | Revenue Sharing | Lobby | Gift Shop |


Prizes & Awards
My Profile



Active Members
TodayLast 7 Days more...






Resources » Articles » Databases »

Nested Trigger or Recursing Trigger in SQL Server


Posted Date: 24 Jun 2008    Resource Type: Articles    Category: Databases
Author: Apurba Kumar SarkarMember Level: Bronze    
Rating: 1 out of 5Points: 4




Nesting means that when a trigger is fired, it will also cause another trigger to be fired.

One Trigger execution can trigger even on another table or same table. This trigger is called NESTED TRIGGER or RECURSIVE TRIGGER.

SQL Server supports the nesting of triggers up to a maximum of 32 levels.

Recursive triggers When a trigger fires and performs a statement that will cause the same trigger to fire, recursion will occur.

Following script will stop executing all the nested triggers.
SP_CONFIGURE 'nested_triggers',0
GO
RECONFIGURE
GO

There is also alternate way to stop Trigger Recursion

ALTER DATABASE databasename
SET RECURSIVE_TRIGGERS ON | OFF




Responses


No responses found. Be the first to respond and make money from revenue sharing program.

Feedbacks      
Popular Tags   What are tags ?   Search Tags  
Sign In to add tags.
(No tags found.)

Post Feedback


This is a strictly moderated forum. Only approved messages will appear in the site. Please use 'Spell Check' in Google toolbar before you submit.
You must Sign In to post a response.
Next Resource: Future Keywords of SQL Server
Previous Resource: Joins in Sql Server
Return to Discussion Resource Index
Post New Resource
Category: Databases


Post resources and earn money!
 
Related Resources



dotNet Slackers

About Us    Contact Us    Privacy Policy    Terms Of Use