Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
| Author |
Topic |
|
fugazi
Starting Member
6 Posts |
Posted - 2009-09-02 : 07:23:16
|
| Hello ! Is it possible to create a trigger on a view for a new entry ? I was thinking about this syntax like on a table but it's not working on a view : CREATE TRIGGER [new reject part] ON [dbo].[vw_HardnessTester] FOR INSERTAS EXEC master..xp_cmdshell 'net send mycomputer New rejected parts entry for hardness'I want to receive a 'net send' for each new entry in this view...What's the problem ? thanks again Daniel |
|
|
afrika
Master Smack Fu Yak Hacker
2706 Posts |
Posted - 2009-09-02 : 07:43:17
|
| duplicatehttp://www.sqlteam.com/forums/topic.asp?TOPIC_ID=131956 |
 |
|
|
visakh16
Very Important crosS Applying yaK Herder
52326 Posts |
Posted - 2009-09-02 : 08:32:49
|
quote: Originally posted by fugazi Hello ! Is it possible to create a trigger on a view for a new entry ? I was thinking about this syntax like on a table but it's not working on a view : CREATE TRIGGER [new reject part] ON [dbo].[vw_HardnessTester] FOR INSERTAS EXEC master..xp_cmdshell 'net send mycomputer New rejected parts entry for hardness'I want to receive a 'net send' for each new entry in this view...What's the problem ? thanks again Daniel
why use trigger for this? wont a job to execute procedure to execute the logic be sufficient? |
 |
|
|
fugazi
Starting Member
6 Posts |
Posted - 2009-09-02 : 19:23:52
|
| Ok so how to do it ? (stored procedure)thank you for your help ! Daniel |
 |
|
|
afrika
Master Smack Fu Yak Hacker
2706 Posts |
Posted - 2009-09-03 : 06:51:51
|
| yes |
 |
|
|
|
|
|