|
[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] Re: Use 'count' or xsl:variable?
Hello, > Jeni Tennison wrote: > .... For example to > count how many books there are with a last_name of 'Austen', you would > use: > > count(/library/book[last_name = 'Austen']) > > (although if you're doing this a lot you'll be better off with a key) I have a similar (and follow up) problem like Marina, so I use her example: Would there be any way to extract a summary containing the last name of the authors and the number of books they have written? like: <executive_summary> <author last_name="Austen" nr_of_books="41" /> <author last_name="..." nr_of_books="..." /> ... </executive_summary> Whatever I was able to think of displayed multiple results for each author. So my problem is to call: count(/library/book[last_name = '$current_author_i_am_dealing_with']) only the first time I encounter him. Thanks on any suggestions, Markus 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
|

Cart








