** Resolved **Abort SQL Server 2000 Stored Procedure FROM VB.Net
hi all,
I have a stored procedure running every night on an SQL Server database which is triggered through a VB.Net App. Sometimes the process is very long and might take a few hours. My problem is that I need to stop it if its taking too much time to be able to run other applications. I want to know if this is possible to do from within the VB.Net App, thas is to abort the processing of a stored procedure and cause it to stop.
All help appreciated thanx.
Re: Abort SQL Server 200 Stored Procedure FROM VB.Net
Hi
Instead of calling the stored procedure directly you and instead create a new job that executes your stored procedure using sp_add_job, then add a new step to the job you created with sp_add_jobstep.
Then add a sp_job_jobschedule and to begin running sp_start_job. If it takes too long you can stop : sp_stop_job.
Regards
Jorge
Re: Abort SQL Server 200 Stored Procedure FROM VB.Net
Thanx mate i'll try this and see, but i'm sure this is the solution to my problem. thanx again, cheers.