I'm trying to transfer a local "subdirectory" tree to a Sharepoint. I have it partially working, but am kind of stumped about why the second folder is failing. Full disclosure I am new to both SSIS and CozyROC.
- Local Directory Root
- Subdirectory1
- Subdirectory2
- Sharepoint Directory Root
- Subdirectory1 (pre-exists)
- file a (works)
- file b (works)
- Subdirectory2 (pre-exists)
I'm using a script task that get's a list of the local sub-directories. This then is passed to a ForEach loop, which is correctly iterating through the local subdirectories.
Inside the foreach loop is a single File Transfer Task. The "Local" paramenter is set to a User::PathVariable which comes from the foreach loop. The Remote parameter is a variable that is made of the following functions:
- RemoteSubDir = REVERSE( LEFT( REVERSE( @[User::PathFolder]), FINDSTRING( REVERSE( @[User::PathFolder]), "\\", 1 )))
- I'm using this to convert \\servername\folder\sub1\LocalDirectoryRoot\Subdirectory1 to "SubDirectory1"
- RemotePath = "Shared Documents/DF_Test/StorReports" + REPLACE( @[User::RemoteSubDir] , "\\", "/" ) + "/"
Watching the variables, I can see no difference in the RemotePath variable as declared for Subdirectory1 and Subdirectrory2 that would should cause this.
Below is the error message I'm getting.
[File Transfer Task] Error: An error occurred with the following error message: "System.Net.WebException: The remote server returned an error: (409) Conflict.
at System.Net.WebClient.UploadFile(Uri address, String method, String fileName)
at System.Net.WebClient.UploadFile(String address, String method, String fileName)
at CozyRoc.SharePoint.Connection.SendFile(String #=zZ5EwcXg=, String #=zTFWs0gE=, Boolean #=zW8oUkIk=)
at CozyRoc.SqlServer.SSIS.FileTransferTask.#=z6FVcsN2snoki(IFtpClient #=zH6wg_AXDSV7o)
at CozyRoc.SqlServer.SSIS.FileTransferTask.#=zVf2P$epJAxnW(IFtpClient #=zH6wg_AXDSV7o)".
This is the "working" folder"
This is the one that will break
Thanks for your thoughts and input!