Quantcast
Channel: Transact-SQL forum
Viewing all articles
Browse latest Browse all 23857

I guess I don't understand Instead-Of-Update triggers

$
0
0

I have a simple Table with a View on it.  The View has an Instead-Of-Update Trigger on it.  Lets say I execute an UPDATE command on the View that affects all rows.  It appears that the Instead-Of-Update trigger is being fired only once, even though all the rows are being updated!  I know that it is being fired only once because I added a 'SELECT GETDATE()' command to the Trigger and I am seeing the resulting date output only once, even though, like I said, all the rows are being updated.

How is this possible?  Am I missing something?  How do I get the Trigger to fire for each row being updated?  This is SQL 2005.

Thanks.


Viewing all articles
Browse latest Browse all 23857

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>