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.

 All Forums
 SQL Server 2000 Forums
 SQL Server Administration (2000)
 Triger a windows service

Author  Topic 

AskSQLTeam
Ask SQLTeam Question

0 Posts

Posted - 2005-12-19 : 09:05:58
Ali Shahbour writes "Hello.
I develeoped an SMS Service. Clients sends there data to a webservice that save the messages to a database.

Then a windows service check the database every 4 min to see if a new message had arrived and send it.

My point is that how can i fire a triger to run any external application when a row is inserted and sending it the data. in this way i can get rid of the looping every 4 min and free some resorses of my system.

By the way the webserice, Database, Windows service each of them are on different PC.

So if you get an idea please tell me and suppose both case if they are on the same PC or Different PCs.

I am using MS SQL 2000, and i am reading 2005 and will upgrade soon."

SQLServerDBA_Dan
Aged Yak Warrior

752 Posts

Posted - 2005-12-19 : 10:13:25
You sure don't want to call an external application from a trigger. You should be able to use xp_cmdshell from a trigger but that would be terrible. The update would be hung up until the external application finished. If you want to free up resources on a server instead of running this application you wrote then I suggest:

1) Take a work station you're not using and install WinXp on it. Name it JobSvr01 or whatever. Move it to the server room. Then use it to run all your tasks like this.
or
2) Buy a new server to upgrade an old one. Use the old server as a job server.


Have fun
Go to Top of Page
   

- Advertisement -