I'm downloading climate data and the files come zipped. Can Alteryx unzip the files as part of the workflow?
The path to one of the files is
http://www.ncdc.noaa.gov/orders/qclcd/QCLCD201601.zip
Solved! Go to Solution.
The post @chris_love refers gives you a lot of detail on how to do this.
I have done this in the past using a Download Tool to get zips and save to temp files and then a Run Command to extract the zip files.
The main trick I used is to create a batch file of all the downloaded zip names and then read in a directory list to get back the filename list.
Have attached my workflow (downlaods from TurtleTrader.com but can easily be changed). I use 7Zip and the formula tool needs the path to this to create the commands.
Hope it helps
This worked just as I needed it. Thanks!
Hi JDukerly,
Thanks for posting your workflow. It works great!
One Question, I'm trying to understand all the places I need to make adjustments if I want the files (Both the DL Zips and the resultant extracts) to be dropped somewhere other than Temp?
Can you provide any guidance?
Thx
Tim
The download tool likes to pull down to the temp directory.
Probably the easiest way is to adjust the create extract cmds to move each file to the target directory, and then extract from there.
I'm not in front of my Alteryx terminal at moment but will stick something together on train home and post it up tonight.
James
Thanks James!
Priority is controlling where the final files will be extracted. If I have to live with the DL tool dropping files to temp I can live with that. I've been trying to play with it myself but I'm missing something somewhere.
Tim
James!
This is amazing. Apologies for th delayed reply, I've been traveling.
I'm having one last issue. I'm getting a truncation error. ConvError: DownloadAndExtractZips (1): Tool #30: FileName: "piz.seliflla/nodsabatad/amrahpdorp/piz/stamrof_tla/spm-phd/ac.cg.cs-ch.www//:ptth" was truncated
I'm assuming it's because my URL is so long (Example: http://www.hc-sc.gc.ca/dhp-mps/alt_formats/zip/prodpharma/databasdon/allfiles_ap.zip). I'm unsure where to adjust.
Thanks again for the example. I learned a ton just from reviewing this.
Tim
Yep had a field limited to 30 characters, have upped it to 2000.
For reference found by pressing Ctrl-F and going to tool 30.
Also published on the Gallery
https://gallery.alteryx.com/#!app/DownloadAndExtractZips/56a7dc323df7da0740bac48d
Let me know if this works for you.