Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Trigger problem
Message
General information
Forum:
Microsoft SQL Server
Category:
Other
Title:
Environment versions
SQL Server:
SQL Server 2005
Miscellaneous
Thread ID:
01391619
Message ID:
01391808
Views:
46
Isn't it the same as
IF UPDATE(cs_enddate) 
in this case ?


>IF you didn't change cs_enddate from anywhere else but from DELETE trigger you could do this in UPDATE Trigger:
>
>IF EXISTS(SELECT 1 FROM INSERTED INNER JOIN DELETED ON Inserted.cs_enddate <> Deleted.cs_enddate)
>   BEGIN
>      --- cs_enddate is updated that means the trigger is fired from DELETE triger
>      RETURN
>   END
>.....
>
>
>But as I said, that is VALID only if you didn't change cs_enddate anywhere else but DELETE trigger.
--sb--
Previous
Reply
Map
View

Click here to load this message in the networking platform