Please start any new threads on our new site at We've got lots of great SQL Server experts to answer whatever question you can come up with.

Our new SQL Server Forums are live! Come on over! We've restricted the ability to create new threads on these forums.

SQL Server Forums
Profile | Active Topics | Members | Search | Forum FAQ
Save Password
Forgot your Password?

 All Forums
 General SQL Server Forums
 New to SQL Server Programming
 SQL job is not writing on remote text flle
 Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic  

Starting Member

45 Posts

Posted - 07/08/2013 :  14:30:51  Show Profile  Reply with Quote
Iam trying to crate a job, that writes the result set on text file and export to location like "\\abc\xyz.txt"

job succeeds but i cant see any thing written on the file and i have given the same path in the job path option.

James K
Flowing Fount of Yak Knowledge

3873 Posts

Posted - 07/08/2013 :  17:09:56  Show Profile  Reply with Quote
If you change the export location to a local drive, are you able to do the export successfully? If you are, then it is a permissions issue - i.e., the login that is running the job does not have write access to the network share.
Go to Top of Page

Very Important crosS Applying yaK Herder

52326 Posts

Posted - 07/09/2013 :  00:59:59  Show Profile  Reply with Quote
how are you trying to do export? is it bcp or SSIS? I guess it should be bcp. I've had this issue couple of times when calling bcp using xp_cmdshell from t-sql procedure. Try running the bcp command in command prompt and see if it succeeds. then it might be permission issue with account that sql agent uses.
In ideal scenario you should create a proxy account for doing this and give it only required access by job like access to your shared path etc. dont use system account for this.

SQL Server MVP
Go to Top of Page

Starting Member

45 Posts

Posted - 07/09/2013 :  16:22:38  Show Profile  Reply with Quote
Go to Top of Page
  Previous Topic Topic Next 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.02 seconds. Powered By: Snitz Forums 2000