Files Older than 60 Days

(imported topic written by JasonO91)

Greetings,

I’ve been working on a custom report to show files older than 60 days and file size of at least 50 MB.

The output should look something like this:

Computer Name | Pathname | Size | Modification Time | Scan Time Length

So anytime I create the relevance to generate the list of files, I can’t seem to get the modification time and size of each file.

pathnames of it whose (modification time of it < now - 60 * day and size of it > 50000) of descendants of folder “C:\Program files”

Anytime I try to concatenate the Size, Modification Time, etc I get errors such as:

(size of it, pathnames of it) whose (modification time of it < now - 60 * day and size of it > 50000) of descendants of folder “C:\Program files”

I’ve got a task that is scheduled for once a day that does the following:

// create a reg value to indicate last time started

regset "

HKEY_LOCAL_MACHINE\SOFTWARE\BigFix\EnterpriseClient

" “LastSearchStarted”="{now}"

// delete temporary file (probably doesn’t exist, but might cause problems if it does)

delete __appendfile

// search computer and results in temp file

appendfile {names of it whose (modification time of it < now - 60 * day) of descendants of folder “C:\Program files” }

// overwrite previous results (if they exist)

delete “{pathname of parent folder of regapp “besclient.exe”}\searchresults.txt”

move __appendfile “{pathname of parent folder of regapp “besclient.exe”}\searchresults.txt”

// create a reg value to indicate last finish started

regset "

HKEY_LOCAL_MACHINE\SOFTWARE\BigFix\EnterpriseClient

" “LastSearchFinish”="{now}"

Any help would prevent further head banging on desk.

Thanks,

Jason

(imported comment written by JasonO91)

I realize that some of the syntax was incorrect for what I want to accomplish, however I still can’t get the proper syntax to return the data that I want. When I create the action to appendfile with

pathnames of it whose (modification time of it > now - 60 * day and size of it > 5000000) of descendants of folder “C:\Program files”

It returns data that it shouldn’t:

C:\Program files\BigFix Enterprise\BES Client__BESData\Enterprise Security\1Superseded.fxf

C:\Documents and Settings\jottwell>dir "C:\Program files\BigFix Enterprise\BES C

lient__BESData\Enterprise Security\1Superseded.fxf

Volume in drive C is Local Disk

Volume Serial Number is 2CDD-AF0E

Directory of C:\Program files\BigFix Enterprise\BES Client__BESData\Enterprise

Security

12/08/2006 03:31p 2,740,774 1Superseded.fxf

Is there any way to debug why the client is returning data that the relevance debugger doesn’t?

Jason

(imported comment written by JasonO91)

Looks as if you play with where the whose it’s long enough you might get something that works =)

(pathname of it as string & " - " & modification time of it as string ) of descendants whose ((modification time of it) > now - 60 * day and size of it > 5000000) of folders “C:\Program files”

Now that the relevance is coded up, maybe a bit of help with the custom report =P

Thanks,

Jason