Trying to update SVN using Powershell in a SQL Server Job as the Service account

251 Views Asked by At

I have a powershell script that I developed and can run fine manually. However when I put the script into a sql server job and attempt to run the following line...

SET-LOCATION "$NewTargetPath\"
TortoiseProc /command:update /path:$SVNRepository /closeonend:3

I get the following error:

Executed as user: myserviceaccount. A job step received an error at line 146 in a PowerShell script. The corresponding line is 'TortoiseProc /command:update /path:$SVNRepository /closeonend:3'. Correct the script and reschedule the job. The error information returned by PowerShell is: 'The term 'TortoiseProc' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the spelling of the name, or if a path was included, verify that the path is correct and try again.  '.  Process Exit Code -1.  The step failed.

I've checked the paths they all look good and I can even run the command from a powershell command line on the server. Any ideas on where to look for why this error may be occurring?

0

There are 0 best solutions below