December 18, 2012 at 5:19 am
hi, I need an example simple indirect recursive trigger.
Thanks.
December 18, 2012 at 5:32 am
Simple thing would be imagine 2 tables, with 1 column.
Trigger on each table after the insert of a value into the column
Insert into Tab1 fires Trig1 which inserts the value into Tab2.
Tab2 trigger fires which inserts the value back to Tab1, which caused the trigger to fire on Tab1
And it goes on and on and on in an endless loop
http://msdn.microsoft.com/en-us/library/ms190739%28v=sql.100%29.aspx
December 19, 2012 at 12:47 pm
jmohan1984.tn.ind (12/18/2012)
hi, I need an example simple indirect recursive trigger.Thanks.
Did you make it beyond the phone interview?
There are no special teachers of virtue, because virtue is taught by the whole community.
--Plato
December 19, 2012 at 5:35 pm
opc.three (12/19/2012)
jmohan1984.tn.ind (12/18/2012)
hi, I need an example simple indirect recursive trigger.Thanks.
Did you make it beyond the phone interview?
ROTFLMAO! +1
My thought question: Have you ever been told that your query runs too fast?
My advice:
INDEXing a poor-performing query is like putting sugar on cat food. Yeah, it probably tastes better but are you sure you want to eat it?
The path of least resistance can be a slippery slope. Take care that fixing your fixes of fixes doesn't snowball and end up costing you more than fixing the root cause would have in the first place.
Need to UNPIVOT? Why not CROSS APPLY VALUES instead?[/url]
Since random numbers are too important to be left to chance, let's generate some![/url]
Learn to understand recursive CTEs by example.[/url]
[url url=http://www.sqlservercentral.com/articles/St
Viewing 4 posts - 1 through 3 (of 3 total)
You must be logged in to reply to this topic. Login to reply