SQL Server Forums
Profile | Register | Active Topics | Members | Search | Forum FAQ
 
Register Now and get your question answered!
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 SQL Server 2008 Forums
 Transact-SQL (2008)
 Running .bat with SQL Job problems
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic  

BruceT
Yak Posting Veteran

USA
77 Posts

Posted - 11/27/2012 :  08:49:20  Show Profile  Reply with Quote
Hi,

Has anyone successfully scheduled a .bat file to run as a step within an SQL Server Agent Job? The .bat file runs fine and does what it's supposed to do when run manually, but when run through the Job it states: The system cannot find the file specified.

Thanks

jimf
Flowing Fount of Yak Knowledge

USA
2869 Posts

Posted - 11/27/2012 :  09:25:45  Show Profile  Reply with Quote
I'm just guessing here, but did you refer to the file with the full url and not just a letter drive?
instead of C:Folder\file.bat, use \\LocationName\folder\file.bat


Jim

Everyday I learn something that somebody else already knew
Go to Top of Page

BruceT
Yak Posting Veteran

USA
77 Posts

Posted - 11/27/2012 :  09:39:29  Show Profile  Reply with Quote
quote:
Originally posted by jimf

I'm just guessing here, but did you refer to the file with the full url and not just a letter drive?
instead of C:Folder\file.bat, use \\LocationName\folder\file.bat


Jim

Everyday I learn something that somebody else already knew



Thanks Jim, I'll give that a try!
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
 Printer Friendly
Jump To:
SQL Server Forums © 2000-2009 SQLTeam Publishing, LLC Go To Top Of Page
This page was generated in 0.05 seconds. Powered By: Snitz Forums 2000