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.

Run same workflow on different input file in same folder with different columns

ginnguyen
5 - Atom

Hi All,

 

I have 10 files in csv with different file names, sheet names, fields but all of them are saved in the same folder.

In each of the csv file there is a product col which i have to replace a new code from a reference file, and the objective is to output the file after product is replaced and keeping the original format of it.

I know i can do 10 inputs and replicate the workflow for each of them. But it is very tedious if i repeat the workflow 10 times. I think macro batch can be a solution but i havent used any macro before. I tried to search similar topics and test some recommended macro but it doesnt work out.

Can you help me with sample macro batch for this task? Thanks so much for your help.

2 REPLIES 2
geraldo
13 - Pulsar

@ginnguyen 

 

and the delimiters are the same as the files?

ginnguyen
5 - Atom

Generally the file name and sheet name are not the same for example spABCXYZ.csv, spGHJkL.csv, spYUOH.csv. they have different fields.

I tried macro batch to input all of them and run workflow to replace on the compile input. But the issue is if i do that way, the compile file will have all combined cols from 10 files. But i want to keep the original format and fields of each file only.

For example:

SpABCXYX has col 1, col 2, product, col 3

SpGHJKL has col 5, col 6, product, col 7, col 8

....

I want to keep the format before they are compiled. Currently when i output the file will have all the combined columns which is not good :(

 

Labels