Hi,
For limiting our data retention, we want to set up Power Automate to delete specific types of files after a certain period, but without reference to the file created date (we need to set our own date for some files). Thanks in advance for any assistance you could provide.
Essentially, we need to delete files based on two conditions:
- Date (eg, over 3, 5, or 15 years) and
- Our document code (eg, delete “ABC” type files, but not "XYZ")
Putting that together, the command would be, for example: delete any file with the code "ABC" that is more than 1095 days since its "start date".
A critical complication to this is we cannot use the standard file created date because the date the file was created may not be the date we need to use as the reference point (eg, the paper document came into existence on 1 October, but the electronic scan was created on 1 December, so the created date is 2 months later than what we require). This is one illustration; there are other reasons we are likely to require the ability to select our own file date.
In share point, we have created new columns for “Doc Code” and “Start date”. For example:

The columns above are something like the columns we wish to use in the power automate delete flow. Is anyone able to suggest how we can set up a power automate to delete only “ABC” code documents after a set time period, eg, 3 years / 1095 days, but (critical) using our own selected dates for the files?
Thanks again,