Skip to content

Add filesize and last modified date on output in Find-DbaOrphanedFile #9009

@frodr1k

Description

@frodr1k

Summarize Functionality

When gathering output from "Find-DbaOrphanedFile" it's a natural to also wanna know the potential diskspace saving opportunitys. As well as also getting an approximation of the files age.

Adding filesize in bytes (or optional in other sizes) will give a quick heads up of potential space saving.

Adding last modified date will help estimation if file SHOULD be removed in the next step.

Is there a command that is similiar or close to what you are looking for?

Yes

Technical Details

It's possible to do this but you need to loop through the results and do a separate look up.

Instead doing something similar to this would be nice to have as an option.

$a = (Get-Item -Path $filename) and then pulling all info from that. (pardon for my 5yearsold PS skills here) .

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions