August 23, 2012 at 12:13 pm
Hi,
From a VB script task in SSIS, I am trying to run a bat file.
Here is my piece of code. This works fine from Visual Studio but when running it under a scheduled SQL job, it hangs.
Any idea? Is there a security warning on server I do not see?
'Run the batch file created previously, to download the raw data files.
Dim myProcess As New Process
With myProcess
.StartInfo.UseShellExecute = True
.StartInfo.Arguments = " /c \\BLMCIK\CMAMS\Monthly\getMonthlyAllFiles.bat"
.StartInfo.FileName = "cmd.exe"
.StartInfo.WindowStyle = ProcessWindowStyle.Hidden
.Start()
End With
Thanks!
August 23, 2012 at 1:08 pm
My first guess would be a permisisons issue. Does the account the SQL Agent job is running under have needed permissions to access that batch file?
Just a thought,
Rob
August 24, 2012 at 6:43 pm
There are no special teachers of virtue, because virtue is taught by the whole community.
--Plato
Viewing 3 posts - 1 through 2 (of 2 total)
You must be logged in to reply to this topic. Login to reply