Execute powershell script from Sql Server Express and NOT wait for it to finish
€8-30 EUR
In Progress
Posted over 7 years ago
€8-30 EUR
Paid on delivery
Call Powershell script from Sql Server and not wait for script to finish.
I have a ps1 script that I call from Sql Server Express. The call is triggered when new entry in table is made.
Usually The entry is made from a web form.
The script takes approx 120 seconds to finish. Now the website just waits until the script completes. I want it to execute script and not wait for it to finish.
Hi,
May I know which SQL Server version are you using? Also if you can share the code of the ps script that would be great.
I believe you are using xp_cmdshell?
IIS/Apache, PowerShell and SQL Work all Included for ASP, HTML5/JS or PHP Site that this integrates into. Can discuss more and ensure that the appropriate outcome is obtained.
Hello.
The best way in your case is to use jobs. Basically MS tells that it follows best practices. In this case you don't have to wait for PS script to complete.