Split a CSV into 3 differents ones

Hello Make community, I would like to transform a CSV file into 3 differents ones.

For example I have a file with 5 rows as follow :

Header : code; type; date; value;

001; fruit; 2025-01-01; 13;

002; vegetable; 2025-01-01; 14;

003; fruit; 2025-01-01; 1;

004; dairy; 2025-01-01; 13;

005; fruit; 2025-01-01; 23;

So i’d like 3 files, one with only fruit, one with only vegetables, and one with only dairy.

I can’t find out how to do it with built-in CSV module. Could you help me ?

Thanks a mil !

Hey Yihui,

in general you want to iterate over the values in the csv file, then use an aggregator set to group them by the type. This should give you 3 different arrays - one for each type. Then transform the arrays back in csv files.

Hello Stoyan,

Thank you for your reply !

When you say “iterate” you mean parse de CSV ?

Yeah, Parse CSV file should give you separate bundles per each entry inside.