Re: Adding subtotals to a report
> Project[current()] That selects all Project elements for which the predicate current() is true current() returns a node set of size one containing the current node, and node sets convert to true if they are non empty. As this is never non empty, it is the same as Project[true()] which is the same as Project > It gives me the same result as if I had used last(). yes last() also always returns a non empty node set. > What I was trying to do was look for a Project element which has an > attribute named ProjectName and the value is equal to the current > ProjectName attribute. When I tried putting current() in there like > so: your descritption refered to two ProjectName attributes but your expression did not refer to any... Project[@ProjectName=current()/@ProjectName] Selects all the Project elements that you describe. Also your example is looking for @Total, ie a Total attribute but your small input example has no such attributes, only TotalDiff David _____________________________________________________________________ This message has been checked for all known viruses by Star Internet delivered through the MessageLabs Virus Scanning Service. For further information visit http://www.star.net.uk/stats.asp or alternatively call Star Internet for details on the Virus Scanning Service. XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
PURCHASE STYLUS STUDIO ONLINE TODAY!
Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!
Download The World's Best XML IDE!
Accelerate XML development with our award-winning XML IDE - Download a free trial today!
Subscribe in XML format