I've written a VB Script to move files from a folder on one server to a folder on another. If I run the script in the operating system, it runs fine but if I run it vai a SQL Job, it reports success but doesn't do the move.
Looking in the Job History, it tells me that I have a permissions problem. I assume this is because the Local System Account that is running SQL Agent doesn't have permission on the remote server.
So, I have three quesitons:
1. How do I give the Local System Account on the server running SQL Agent permission to write files on the remote server?
2. Some posts that I've looked at suggest that if I create a .bat to call the CScript and then call the .bat from the SQL JOB, it will work. If this is true, why would a .bat have permissions?
3. All the posts I've seen are very old. Is there a newer better way of doing this?