Hi,
I have very huge data which I want to segregate and save in multiple files.
Same Data:
Country | City | Person | Age | Income |
India | Delhi | Ram | 28 | 1000 |
India | Delhi | Sita | 27 | 900 |
India | Delhi | Mohan | 29 | 980 |
India | Mumbai | Mohit | 30 | 950 |
India | Mumbai | Misha | 7 | 0 |
Australia | Sydney | Mark | 20 | 200 |
Australia | Sydney | John | 18 | 150 |
Australia | Perth | Micheal | 45 | 5000 |
Australia | Perth | Eric | 38 | 2500 |
Australia | Perth | Colette | 15 | 350 |
Australia | Melbourne | Isable | 21 | 600 |
US | New York | Mark | 26 | 750 |
US | Washington | Jack | 29 | 800 |
US | Washington | Mike | 24 | 500 |
US | Seattle | Simon | 36 | 3500 |
US | Seattle | Jack | 41 | 4700 |
US | Chicago | Kelvin | 27 | 550 |
US | Chicago | Imran | 33 | 1100 |
US | Chicago | Andy | 55 | 650 |
First I want to create folder with "Country" name. Each "Country" folder should have sub-folder with "City" names. Then each sub-folder should have Files with "Person" name. Like below-
Kindly help me in creating a workflow for this.
Regards,
Mohit
Solved! Go to Solution.
@mohit9garg See if the attached sample points you in the right direction. There are a couple different methods, but I think the render tool is the easiest if it can accomplish what you're after.
Wherever this workflow is saved, it will create the folders and subfolders and write each person's info out to their file. Hopefully you can tweak this for your needs.
Hi @mohit9garg,
I always use the CMD tool in order to create new folders.
Here you can find a link for a workflow that you can test:
This workflow now is using the temp folder so it should be changed to for example C:\Test\
After you will change it the workflow will create folders for each of the positions in this column:
After you will create those high-level columns you will need to create new folders within them and in order to do so, you will need to use the block until done tool to ensure that first, you will create new folders before you will move forward with the subfolders.
@patrick_digan can we use it through Output tool. Render tool will take more time than Output tool, given no. of files are ~200.
Hi @mohit9garg,
I have updated the workflow with your data.
First, it creates Country Folder Afterwards cities folder and at the last stage it puts everything in the relevant folders:
Please keep in mind that you need to update temp positions to show the correct folder. For example, it can be replaced with C:\
I think this solution should suit your needs!
Hi @mohit9garg,
Apologies I needed to amend the workflow in order to make it work. It isn't so easy to change the version for the yxzp file.
So I amended the file in order to make it work.
Now the output file is D:\, not the temporary location.
You would need to change it here in order to suit your needs.
Hi @Emil_Kos
My folder names contain "space"; seems it is causing problem.
Is there any fix for that too?
Regards,
Mohit