Let’s talk Alteryx Copilot. Join the live AMA event to connect with the Alteryx team, ask questions, and hear how others are exploring what Copilot can do. Have Copilot questions? Ask here!
Start Free Trial

Alteryx Designer Desktop Discussions

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

How to unzip a file using Alteryx? What is the code ?

Sunithaprdp
8 - Asteroid

Hi, 
i would like to unzip a file using Alteryx and could you please help me with the code that we should use?

 

The zip file consist of three different formats of files (PDF,.dat and excel)

Hence, the intention is to unzip the file , convert .dat file to .txt , rename file and move to a desired location.

 

Could someone help me on this?

2 REPLIES 2
Deano478
12 - Quasar

@Sunithaprdp This previous post should hopefully provide you with the guidance you need: 

 

https://community.alteryx.com/t5/Alteryx-Designer-Discussions/Can-Alteryx-unzip-a-file-as-part-of-th... 

FinnCharlton
13 - Pulsar

Hi @Sunithaprdp,

You'll need the 'Run Command' tool for this one. You can write a command using the formula tool, using something like PowerShell to perform the unzipping. Something like this should work:

 

mkdir [New Folder Path]

powershell -command Expand-Archive -Force '[.zip File Path]' '[New Folder Path]'

 

You can add additional commands to rename and move the file. After forming the commands you can run them using the 'Run Command' tool. Use a configuration like this:

FinnCharlton_0-1675259712849.png

 

Labels
Top Solution Authors