Click here to Skip to main content
15,065,328 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
When data collected we restore of database backup file to another server where I am executing some store procedures sequentially.As procedure executing time from 25 mins to 7 hours approx.But now we are now making this task should run from UI.I want to know which is proper way to execute this long running procedures from UI whether Windows application or Web Application?After procedure executed successfully we again restore database to live server.

What I have tried:

Right now I am running this procedure on server directly by execute command on SQL Server.But this process(task) is more tedious and complex.This takes long time and causing issues when some times process wrongly executed (e.g.- due to wrong parameter ...etc). For this I have created one windows application but as database is on another server we need to install this application on server also .I would like to know which is best application Web or Windows to execute long running procedures in UI?
Posted
Comments
[no name] 27-Dec-17 16:37pm
   
If your requirement permits you can even create any windows service and invoke your stored procedure which can run in background. This service can send you notification when it start/end/error out or time to time status on mail. But also the windowds service needs to install on server where you intend to run and does not have any user interface.
suresh shewale 28-Dec-17 5:07am
   
thanks your suggestion but i need UI so that it can controlled by another user easily and some times it required human intervention .
[no name] 28-Dec-17 8:53am
   
If you need your SP to be triggered from any sort of UI you can create Forms and invoke this SP. If you have only 1 SP to be executed you may not be able to track progress and it will either only run/fail and you need to wait untill the SP complete to see the results. If you are invoking more than 1 SP in sequence you may implement logic to track current running status and see it on your UI.
vivvicks 27-Dec-17 22:52pm
   
Sql server jobs can help you out as they come with steps where u can add dependency of previous step.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)




CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900