Alteryx Designer Desktop Discussions

Find answers, ask questions, and share expertise about Alteryx Designer Desktop and Intelligence Suite.
SOLVED

Delete file from SFTP

HeinL
7 - Meteor

I successfully created a workflow that downloads a file from SFTP.  After processing the file I want to delete the version on the SFTP site.  I copied my download workflow and changed the HTTP Action to DELETE. I add some screenshots of my workflow and some of the settings.  When I run the workflow I get no error messages but the file is not deleted.  I looked for a solution in the Community but can only find mentions of up- and download problems.  Anyone solved this yet?WorkflowWorkflow

 

 

Input from ExcelInput from Excel

 

 

Download ConfigurationDownload Configuration

 

 

Download ConfigurationDownload Configuration

 

 

 

 

36 REPLIES 36
anthony
11 - Bolide

It is my understanding that the DL tool uses CURL, which means you would need to pass additional parameters for curl to know what to do other than your typical http request.

 

Here is a random site that shows SFTP examples.

http://www.dotnet-tutorial.com/articles/curl/how-to-use-curl-command-line-tool-with-ftp-and-sftp

 

I have seen workflows where people just use Command tool and directly pass curl parameters so they have more control since the DL tool seems to be limited.

 

I have been using WINSCP command line option for SFTP since I have to SSH and it works well but requires figuring out their scripts and fingerprint.

HeinL
7 - Meteor

Hi Anthony

 

I am trying our suggestion.  It will take a bit of fiddling but I think it can work.

 

Thanks.

SeanAdams
17 - Castor
17 - Castor

Hey @HeinL,

 

Just following up on this thread - did this manage to get you to a solution that helped?   If it did, would you mind marking this thread as solved using (the green Solution button) so that we can close this thread and add it to the knowledge base that comes up when a user searches in Alteryx?

 

If you are still struggling - feel free to reply on the thread and we can iterate with you to get you to a solution.

 

Thanks @HeinL

Sean

HeinL
7 - Meteor

Due to security settings that do not allow applications like Alteryx to delete from our SFTP site I could not get the suggested solutions to work.  The suggestion to install Fiddler provided the answer about the security settings.  

JeffreyH123
5 - Atom

I have tried all solutions and can not delete files from the SFTP server. Is there an actual example that has worked?

HeinL
7 - Meteor

Hi Jeffrey

 

I could never get it to work.  The solution seems to be to write commands in a .bat file and execute that as an event in the Alteryx workflow.  I have not tried it yet.  

JeffreyH123
5 - Atom
I have not found a way for Alteryx to delete files natively. The solution involves having Alteryx create a batch file using WinSCP script and executing when the workflow (downloads the files) completes with no errors. It would be great if they fixed it!

________________________________

CONFIDENTIALITY NOTICE
NOTICE: This message is intended for the use of the individual or entity to which it is addressed and may contain information that is confidential, privileged and exempt from disclosure under applicable law. If the reader of this message is not the intended recipient, you are hereby notified that any printing, copying, dissemination, distribution, disclosure or forwarding of this communication is strictly prohibited. If you have received this communication in error, please contact the sender immediately and delete it from your system. Thank You.

________________________________


________________________________
ksnow
5 - Atom

Did anyone every figure out to delete a file from a SFTP server? I have read/write/delete access and I can't get files to delete with Alteryx. I can manually delete with Filzilla just fine. Thanks for your insight. 

mceleavey
17 - Castor
17 - Castor

Hi @patrick_mcauliffe, thanks for this.

I'm having difficulty getting this working. It appears to run, and I can see the download tool returning the correct contents of the file in the ftp location, but it's not applying the delete command. 

I'm attempting to use the download tool to delete dynamically determined filenames from the location. I've tried using multiple urls as you outlined here, with the filename as part of the string, but this is not deleting the files.

Do I need to approach this using the generic url to the ftp location then feeding in the filenames as part of the header/payload?

 

Many thanks,

 

M



Bulien

patrick_mcauliffe
14 - Magnetar
14 - Magnetar

@mceleavey  yes, that's the first approach I would try.

 

If that doesn't work, try it in a tool that already works while Fiddler is open in the background.  That should give you the detail you need to replicate it in Alteryx.

Labels