[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

Re: Problem with Muenchian grouping

Subject: Re: Problem with Muenchian grouping
From: "Dimitre Novatchev" <dnovatchev@xxxxxxxxx>
Date: Mon, 10 Nov 2003 19:25:53 +0100
muenchian composite
> I group elements that have an <action> child by name and then for each
group I
> build an HTML table. Members of the same group usually have the same set
of
> childnodes, but this is not always the case, and this is a problem, given
the
> way I build the tables: I get the first member of the group and set the
> headers of the table to the names of its children (<th align="center"
> bgColor="lightgrey"><xsl:value-of select="name()"/> </th>). When other
members
> of the group have more children, the values of those latter are put in a
new
> column without header...
>
> So, instead of getting the first member of the group, I would like to get
the
> one with the greatest number of children (to get all the headers, it's not
a
> problem if some fields are blank in the table). Is this possible?

This is possible, but you have a wrong idea about the problem. Even if you
use the element with biggest number of children, there might be other
elements in the same group that have children, whose name will not be
represented in the column header.

What you really need is all different names of all children of all elements
in a group.

This is nested grouping and has a standard solution using the same Muenchian
method.

Please, give a minimal complete example of a source xml document and many
people in this group will be glad to provide the solution.


=====
Cheers,

Dimitre Novatchev.
http://fxsl.sourceforge.net/ -- the home of FXSL





 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list


Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.