SQLTeam.com | Weblogs | Forums

Execute Process Task working in BIDS and Integration Service but not in SQL job

sql2008r2

#1

hi,

I have every simple SSIS package, load excel file into Table and rename the excel file. It was working when the excel file and rename bat file was in the same server. Now it is moved to different machine. Execute Process task stopped working in SQL job, it is hanging and not returning any error, it needs to be manually stopped. But works perfectly from BIDS and when execute the package under Integration service. I am really confused and not able to resolve.

here is the rename.bat file code


@echo on

rem working code
for /f "tokens=2-8 delims=.:confused: " %%a in ("%date% %time: =0%") do set DateNtime=%%c%%b%%a-%%d%%e%%f.%%g
rem echo %DateNtime%

cd \etcfrefile01\cashcall_files\

rem rename \servername\foldername\Book.xls "book-%~n1%THEDATE%-%~n1%THETIME%.xls"

rename \servername\foldername\book.xls "book-%DateNtime%.xls"


owner of package is sysadmin account but the SQL agent account is not sysadmin, is this can be possible reason for not working. Can i run the job in owner account than SQL agent account. Is yes, where should I change that.

Please help, thanks in advance.