I have a bunch of subfolders in SharePoint and I am wondering about how would I go about automatically deleting files within them if the folder name doesn't match the beginning part of the file name? For example in my screenshot, the sub folder name is "J0000-1002", so I would remove any file that doesn't start with "J0000-1002". The sub folders will have different names so this would need to be dynamic based on the sub folder name.
I am fairly new to Power Automate and was wondering if this is possible. I was thinking of using the trigger "When a file is created or modified" but not sure how to apply it to multiple sub folders. Any help would be appreciated, thanks!