View Single Post
  #2 (permalink)  
Old May 18th, 2005, 09:58 AM
shahchi1 shahchi1 is offline
Friend of Wrox
 
Join Date: Jan 2004
Location: , , USA.
Posts: 303
Thanks: 0
Thanked 0 Times in 0 Posts
Default

you mean calling a stored procedure within a trigger

You can...but ask yourself two times you really wanted to do that

an example from BOL, it uses xp_sendmail extended stored procedure

USE pubs
IF EXISTS (SELECT name FROM sysobjects
     WHERE name = 'reminder' AND type = 'TR')
DROP TRIGGER reminder
GO
CREATE TRIGGER reminder
ON titles
FOR INSERT, UPDATE, DELETE
AS
EXEC master..xp_sendmail 'MaryM',
     'Don''t forget to print a report for the distributors.'
GO
Reply With Quote