one of two things likely going on.
1) the userid that the sql server is running on does not have rights to the file your looking for. Remember that when you connect to the SQL server you use your sql or domain account depending on how you connect. But when you use XPcommand shell you use the domain user that the SQL service is running under. Try logging into the domain on the SQL server box under the id that the SQL server is running under and see if you can see the file.
2) you specify c: But which C: are you looking for. Typically it is safer to specify full paths like \\someserver\someshare\myfile.txt. When you specify c: you need to realize it is not the c: of the client computer, it is the C: of the server, accessed by the user id that the SQL engine is running under.
Hope this helps what you described is a common problem.
Please post if this fixes your problem and if so which issue, 1 or 2.
|