Hi all. Yes, it's me again. LOL
My question is this: Can I program something in the way of a trigger or a sproc that when a certain field is populated (on insert/update) that it calls a VB application or some other external program (possibly a web app?)
If not, does anyone have any suggestions on how I might accomplish this for SQL7? We have actually begun testing to upgrade our 7DBs to 2K, so if it's possible to do something like this in 2K that will also work for me.
Thanks for all the help you guys provide me! I need every bit of it sometimes!
Dirkuse xp_cmdshell in your trigger.
"tnjazzgrass" wrote in message
news:2430444.1043362868@.dbforums.com...
> Hi all. Yes, it's me again. LOL
> My question is this: Can I program something in the way of a trigger
> or a sproc that when a certain field is populated (on insert/update)
> that it calls a VB application or some other external program (possibly
> a web app?)
> If not, does anyone have any suggestions on how I might accomplish
> this for SQL7? We have actually begun testing to upgrade our 7DBs to
> 2K, so if it's possible to do something like this in 2K that will also
> work for me.
> Thanks for all the help you guys provide me! I need every bit of it
> sometimes!
> Dirk
> --
> Posted via http://dbforums.com (http://dbforums.com/)|||As Radzi says you should use the system extended sored procedure xp_cmdshell within a trigger. Something like this will do the trick:
CREATE TRIGGER tr_myTrigger ON dbo.myTable
FOR INSERT, UPDATE, DELETE
AS
DECLARE @.Cmd varchar(1000)
BEGIN
SET @.Cmd = 'c:\..\program.exe'
EXEC master..xp_cmdshell @.Cmd, NO_OUTPUT
END
Cheers!sql
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment