Advent of Code is back! Unwrap daily challenges to sharpen your Alteryx skills and earn badges along the way! Learn more now.

Alteryx Designer Desktop Discussions

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

How do I use the 'Run Command' tool fror unzipping a file?

aroos
7 - Meteor

Hi there.

 

I have a problem and I hope there is someone out there that might help out.

I am trying to unzip a file and put the unzipped file in a particular directory. I am using 7-zip in windows and I have been succesful in using this command by using the Windows command line tool (cmd.exe).

 

 

"C:\Program Files\7-Zip\7z.exe" e "-oC:\Temp\Outputdir" "C:\Temp\myzipfile.zip"

Outputdir is the name of the outputdirectory and myzipfile.zip is of course the zip-file in question.

 

 

I have tried many different combinations but haven't been able to unzip the file using the 'Run Command'-tool. Below is a picture of one of many versions I have tried.

 

 

2017-03-20 18_02_13-Alteryx Designer x64 - New Workflow3_.png

 

 

I would very much appreciate if someone knows how to do this and could publish a solution to this problem. If possible I just wnat to use the 'Run Command'-tool and only use the configuration options that comes with it.

 

Thanks,

Andrée

4 REPLIES 4
patrick_digan
17 - Castor
17 - Castor

@aroos I'm attaching a working example, but i think the only thing that would need to change on your picture is you would need to either have some output or some input. I've setup my example where I attached a text input and write it to a dummy temp file:

 

Capture.PNG

 

Alternatively, you could have the run command tool read in a dummy file. Note that it could also presumably be used to read in the files that you're unzipping.

MarqueeCrew
20 - Arcturus
20 - Arcturus

Have you tried using an INPUT tool to read the zipped file and then using an OUTPUT tool to write to the desired directory?

 

Just saying....

m

Alteryx ACE & Top Community Contributor

Chaos reigns within. Repent, reflect and restart. Order shall return.
Please Subscribe to my youTube channel.
aroos
7 - Meteor

Thanks for the reply.

I assumed there was a way to do this by only using the Command and Command Arguments input since all other inputs were marked as optional, though this doesn't seem to be the case.

I will use your suggestion henceforth.

aroos
7 - Meteor

@MarqueeCrew

 

Thanks for the reply. I didn't know there was a zip-option to the input tool, which is great. It doesn't seem to be enough in my particular case since i need to do some file processing that is quite dynamic and I think I need the Run Command tool in conjunction with the Directory Tool to accomplish this task.

Labels