seschu01

Ok,

I have a network folder called A

I have a SharePoint (2007) Document Library site called B. Web Client is enabled on the server and B is mapped as a Drive (let's call it Y for this discussion)

I want to move documents in A to B. Easy enough, right Not so....

I first started by creating a batch file that issues a COPY \\A \\Y /Y at the command prompt. Viola! Worked Great!

I then moved that command to a SQL Agent job as a CMDExec statement (exact same statement) and attempted to run it.....CRASH! It found the files in A but then said "The system cannot find the path specified"

Ok, so I tried it in SSIS. CRASH! Checked the error log. Same thing...

So I then checked the account under which the SQl Agent was running (special domain account for all our SQL Servers). Thinking it might mater I changed it to run under my name (I'm in Domain admin). I also ensured I had permissions to the SPS 2007 library as well. (I did).

Ran again! CRASH! Same error....

So, I created a batch file , placed thec ommand in the batch file and ran that from the command prompt! Viola! Worked Great.

So, I was thinking of how ingenious I was as I pasted my C:\RootCopy.bat into my SQL Agent job. With a big grin on my face I right clicked and picked "Start Job at step".......CRASH! Same error.

Does anyone have any ideas on this

Thanks,

Stephen




Re: SharePoint - General Question and Answers and Discussion Copy files from Mapped File Server to SharePoint Library using SQL Agent - Fails, any ideas???

Joey Arreza

If this is a batch file that run from a command line, why not use the scheduler to run it

Thanks,

J





Re: SharePoint - General Question and Answers and Discussion Copy files from Mapped File Server to SharePoint Library using SQL Agent - Fails, any ideas???

KevinRhino

Hi

What about using VB Script to do your copying in SSIS and not a CMD File.

http://forums.microsoft.com/MSDN/ShowPost.aspx PostID=1398059&SiteID=1

The above link demonstrates how to write and run VB Script inside SSIS.

Thanks

Kevin