Reading multiple files content

have a few small xml files, which content I would like to get in the analysis. I have tried the following relevance:

q: lines whose (it does not contain "xml version") of (find files "info.xml" of (descendant folders of folder "d:\_snapshots"))

       A: <snapshot>
       A:   <type>single</type>
       A:   <num>1</num>
       A:   <date>2015-04-13 14:00:01</date>
       A:   <description>timeline</description>
       A:   <cleanup>timeline</cleanup>
       A: </snapshot>
       A: <snapshot>
       A:   <type>single</type>
       A:   <num>10</num>
       A:   <date>2015-04-13 23:00:01</date>
       A:   <description>timeline</description>
       A:   <cleanup>timeline</cleanup>
       A: </snapshot>
       A: <snapshot>
       A:   <type>pre</type>
       A:   <num>19</num>

There is one answer per one line of all files. How to get one answer per one xml file content?

This seems to work in the Fixlet Debugger. Not sure when used in analsysis.

(concatenations of lines whose (it does not contain "xml version") of it) of (find files  "*.xml" of descendant folders of folder "C:\Program Files (x86)\BigFix Enterprise\BES Client\__BESData")

You might also think more about how you search for the files and look for something more efficient than find.

files (whose name of it = "info.xml") 

Your milage will vary with descendant folders depending how deep your folder structure is.

1 Like
(concatenations of lines whose (it as lowercase does not contain "xml version") of it) of descendants whose(name of it as lowercase = "info.xml") of folders "d:\_snapshots"

As @gearoid points out, the descendants and descendant folders inspectors are expensive and slow depending on the situation, so be careful. It is best to use them in an analysis property with a limited report time. (Once a day)

The solution works perfectly for me. Thank you very much for your help with relevance and hint concerning descendants.