Topic "Root folder deleted using PutFiles with remove switch enabled"

Author Message
torix
[View user's profile]

Joined: 2015-11-11
Posts: 16
Location: Norway
I observe that when using the PutFiles-method, the root folder given as source is deleted as well. Eg. defining "C:\TEMP\DATA" as a source, the DATA folder is deleted too. I tried "C:\TEMP\DATA\" as source but with the same result.

Short question then : how can I keep the source folder?
(yes, an option would be to create it afterwards)
Advertisements
martin
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 24553
Location: Prague, Czechia
Use C:\TEMP\DATA\* to upload (and delete) just files (and subdirectories) in the directory, not the directory itself.
torix
[View user's profile]

Joined: 2015-11-11
Posts: 16
Location: Norway
torix wrote:
I observe that when using the PutFiles-method, the root folder given as source is deleted as well. Eg. defining "C:\TEMP\DATA" as a source, the DATA folder is deleted too. I tried "C:\TEMP\DATA\" as source but with the same result.

Short question then : how can I keep the source folder?
(yes, an option would be to create it afterwards)


This worked great however, the files in the C:\TEMP\DATA folder itself are not moved, just sub folders and the contents within these.
martin
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 24553
Location: Prague, Czechia
torix wrote:
This worked great however, the files in the C:\TEMP\DATA folder itself are not moved, just sub folders and the contents within these.

Please attach a full session log file showing the problem (using the latest version of WinSCP).

To generate log file, set Session.SessionLogPath. Submit the log with your post as an attachment. Note that passwords and passphrases not stored in the log. You may want to remove other data you consider sensitive though, such as host names, IP addresses, account names or file names (unless they are relevant to the problem). If you do not want to post the log publicly, you can mark the attachment as private.
Advertisements

You can post new topics in this forum






Search Site

What is WinSCP?

It is award-winning SFTP client, SCP client, FTPS client and FTP client integrated into one software program for file transfer to FTP server or secure SFTP server. [More]

And it's free!

Donate

About donations

$9   $19   $49   $99

About donations

Recommend

WinSCP Privacy Policy

WinSCP License