June 20, 2002 at 12:10 pm
Ladies and Gents here's the problem. I created a job that launches a batch file. The batch looks for a file on the AS400. If it finds it, it copies a file to the SQL 7.0 svr. The AS400 is mapped as the 'W:' drive on the sql svr. When trying to run the job, I get this message. CMD.EXE System Error Network Name was deleted. When I run the batch by itself from DOS it runs without a hitch. But in SQL it errors out. Plus, when I change the drive to a local drive it works also. Suggestions?
June 20, 2002 at 12:37 pm
If the system share was not created with the same account that the SQL Server service is running under it will not see that share. If it is running under the system account you need to set it up with a domain account so that you can access the network first, then log onto the server as that user to create the share.
Unless you are required to enter a password to access the network share you could change your batch file to use the UNC name \\Server\Share\file instead of using a mapped network drive. Drive mappings have security vulnerabilities.
June 20, 2002 at 12:42 pm
quote:
If the system share was not created with the same account that the SQL Server service is running under it will not see that share. If it is running under the system account you need to set it up with a domain account so that you can access the network first, then log onto the server as that user to create the share.Unless you are required to enter a password to access the network share you could change your batch file to use the UNC name \\Server\Share\file instead of using a mapped network drive. Drive mappings have security vulnerabilities.
danw thanks for the suggestion, unfortunately, mapping to this drive does require a password.
June 20, 2002 at 1:58 pm
Well, then the first part should work for you.
Let me know if you have any issues.
DanW
June 20, 2002 at 4:48 pm
Take a look at this thread. http://www.sqlservercentral.com/forum/topic.asp?TOPIC_ID=2490&FORUM_ID=20&CAT_ID=2&Topic_Title=Accessing%20an%20AS400%20File%20Share%20from%20SQL&Forum_Title=Connecting Ultimately they ended up using Active Scripting to first create the mapped drive then move the files over.
"Don't roll your eyes at me. I will tape them in place." (Teacher on Boston Public)
June 21, 2002 at 7:56 am
Antares686 -- Your thread was very helpful. My AS400 admin created an account to the AS400 which matches the sql login. It works!! Thanks to everybody who responded especially Antares686!
Viewing 6 posts - 1 through 5 (of 5 total)
You must be logged in to reply to this topic. Login to reply