Apply XPath on collection

Having trouble installing Oxygen? Got a bug to report? Post it all here.
Seb
Posts: 23
Joined: Mon Feb 20, 2017 8:03 pm

Apply XPath on collection

Post by Seb »

I want to evaluate an XPath on a collection like this:

string-join(
collection("file:/C:/Users/me/my-folder/")//biblStruct/@xml:id,
" "
)

I expect the XPath to have one final result of type string. But oXygen seems to return something depending on the selected scope. When using "current file", the XPath is only applied to the current file, when selecting "Project" or "Working sets", oXygen applies the XPath to each file *separately*.

How to really apply the XPath to a collection of files and obtain exactly *one* result?
Radu
Posts: 9451
Joined: Fri Jul 09, 2004 5:18 pm

Re: Apply XPath on collection

Post by Radu »

Hi,

Unfortunately the scope does not behave as an XML collection(). The XPath is simply applied on each file from the scope. We already have an issue on our side to look into how we could make your use case work, if we manage to do that in a future version we'll update this forum thread.

Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
Post Reply