We are celebrating the 10-year anniversary of the Alteryx Community! Learn more and join in on the fun here.
Start Free Trial

Alteryx Designer Desktop Discussions

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

change data format for multiples files

yc151
7 - Meteor

hi, i have a quick question about change data format for multiples files. Now I have many excel files that have same data format(say one file for each car brand, the only difference is different files have different number of rows). I just need to do some transpose/cross/subtotal functions. I already built a workflow to do it for one file. Is there any way to have alteryx do it for all the files I have? Thanks.

 

 

7 REPLIES 7
AngelosPachis
16 - Nebula

Hi @yc151 ,

 

Yes, you can create a batch macro to read each one of those files, do the transpose/crosstab/summarize functions (that should be consistent across all files) and then write the output to the same filepath

yc151
7 - Meteor

Thank you @AngelosPachis , can you share how to write a such macro? or similar macro? 

AngelosPachis
16 - Nebula

Hi @yc151 ,

 

Here's an example. I would suggest you also spend some time to go through the macros Interactive lessons if you haven't done that already.

 

Let me know if you have any further questions.

 

Cheers,

Angelos

 

 

yc151
7 - Meteor

hi, @AngelosPachis 

Thank you for the sample. I opened your macro and replaced my series of tools to your transpose tool. I linked to the file path has my many input files. In the macro, I relinked to one of my input files and relinked to output files, and run into a error message, can you look?

AngelosPachis
16 - Nebula

@yc151 can you try reconfiguring your output tool so you select a sheet to write to? It seems this is causing the issue

 

yc151
7 - Meteor

hello, @AngelosPachis I have finally be able to finish these! thank you, it's helpful! i will learn more macro when i have time.

ArtApa
Alteryx
Alteryx

Hi @yc151 - A batch macro can be a good solution for you. You may learn about types of macros in Alteryx and how to design a macro here: https://community.alteryx.com/t5/Interactive-Lessons/tkb-p/interactive-lessons/label-name/Macros

 

However, there is a chance that a Dynamic Input will also do a job for you. You can potentially (must be the same schema) read all your files process them and then Output to one or many files.

 

a) Please review Dynamic Input sample:

ArtApa_0-1645568641742.png

 

b) Please review Output Data sample:

ArtApa_1-1645568765780.png

 

 

Labels
Top Solution Authors