Start Free Trial

Alteryx Designer Desktop Discussions

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

Choose files conforming to a particular schema

Biswarun
8 - Asteroid

I have a folder that contains different CSVs conforming to different schemas (say, 3 of type A, 4 of type B, and 2 of type C). I have a particular data-analysis workflow designed for type B, stored in a macro, which I wish to loop for the 4 files of type B only (and produce corresponding outputs).

 

If my directory had only contained those 4 files, there would have been no problem at all. But such cannot be the case. I even tried to integrate dynamic input in the mistaken belief that the template specifies the schema and it did not work. So, what is the way out?

2 REPLIES 2
Qiu
21 - Polaris
21 - Polaris

@Biswarun 
Can we assume you have a definition of your intended schema, say a list of Column Names?

FilipR
11 - Bolide

@Biswarun If by "schema" you mean column names, then you can Transpose your CSV Input first and check if a column or columns exist. Please see the attached example. I first transpose the workflow, then count the occurrences of column "GGG" and then finish with a filter that will parse everything into the True anchor if the column was found,

 

FilipR_1-1658912530166.png

 

 

Labels
Top Solution Authors