Categories of files

I have a lot of zip files that have the following conditions and features:
1- First, the names of the zip files are made up of numbers or letters and are separated by the “" sign
2- The names are different at first glance, but after the 2 "
” signs, there is a number that starts with zero, which is very similar to a phone number.
3- An example of the names is dsfsdfe354_3516883_0044******392.zip
4- For example, if there are 1000 of these files, a number of these (indeterminate number) numbers that look like phone numbers are the same (maybe 5 or 6 files).
Now I want you to design a workflow for me
1- First, read the files and categorize the files based on the phone number that is included in the file name.
2- Create a folder called that phone number and upload the files inside it
Please guide me how to design this workflow

Hi @alex1368 , so just to clarify…

Are all the files currently in one folder?

So you want to create a series of subfolders based on the final digits after the second underscore _ in each file name and then move all files with that matching number into the sub folder?

Is that the requirement ?

Does this give what you need?

The workflow has two parts. The first part creates a demo “source folder” in the C:\temp\demo\mydemofiles folder (location defined in the Variable Creator node) and it populates it with 1000 files of a name format similar to what you describe.

The main (lower) part of the flow organizes them into the target location defined as
C:\temp\demo\myorganizedfiles

e.g.

becomes this:

Thank you for your good answer
Does this workflow also move the contents of the files?
My data is a zip file and I want this to be done on them

Hi @alex1368 , the workflow moves the files. I’m not sure what you meant by “move the contents”. It doesn’t unzip them, if that’s what you mean.

Thank you, this issue solves my need.

1 Like

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.