This is the mail archive of the
xsl-list@mulberrytech.com
mailing list .
Re: Re: grouping
- To: xsl-list at lists dot mulberrytech dot com
- Subject: Re: Re: [xsl] grouping
- From: "Günter Pretterhofer" <guenter dot pretterhofer at web dot de>
- Date: Fri, 18 May 2001 19:25:44 +0200
- Organization: http://freemail.web.de/
- Reply-To: xsl-list at lists dot mulberrytech dot com
Hi Oliver,
> > When I try something like
> > <xsl:for-each select="ROW[country=$country]
> > [not(language=preceding-sibling::ROW/language)]/language">
> > the result is english, french and german when specifying Switzerland
> > as country.
> >
> > And when I try
> > <xsl:for-each select="ROW
> >
> > [not(../ROW[country=$country]/language=preceding-sibling::ROW>[country=$country]/
> > language)]/language">
> >
> > the result is german.
>
> Oh, really? :-)
> Isn't it the other way around?
Yes, you are right - sorry.
> According to your input: very simple
> <xsl:for-each select="ROW[country=$country]/language">
>
> Or do you have another, say Switzerland/french ROW?
>
Yes, I have some more "Switzerland/french" ROWs - I must
use this "preceding-sibling stuff" to get unique values.
Thanks for your answer.
Günter
xsl-list@lists.mulberrytech.com schrieb am 18.05.01:
> Hi,
>
> > <page>
> > <ROWSET>
> > <ROW>
> > <country>Canada</country>
> > <language>french</language>
> > </ROW>
> > <ROW>
> > <country>Canada</country>
> > <language>english</language>
> > </ROW>
> > <ROW>
> > <country>Switzerland</country>
> > <language>german</language>
> > </ROW>
> > <ROW>
> > <country>Switzerland</country>
> > <language>french</language>
> > </ROW>
> > </ROWSET>
> > </page>
> >
> > When I try something like
> > <xsl:for-each select="ROW[country=$country]
> > [not(language=preceding-sibling::ROW/language)]/language">
> > the result is english, french and german when specifying Switzerland
> > as country.
> >
> > And when I try
> > <xsl:for-each select="ROW
> >
> [not(../ROW[country=$country]/language=preceding-sibling::ROW[country=$country]/
> language)]/language">
> >
> > the result is german.
>
> Oh, really? :-)
> Isn't it the other way around?
>
> > My favourite result were german and french when specifying Switzerland.
>
> According to your input: very simple
> <xsl:for-each select="ROW[country=$country]/language">
>
> Or do you have another, say Switzerland/french ROW?
>
> Cheers,
> Oliver
>
> /-------------------------------------------------------------------\
> | ob|do Dipl.Inf. Oliver Becker |
> | --+-- E-Mail: obecker@informatik.hu-berlin.de |
> | op|qo WWW: http://www.informatik.hu-berlin.de/~obecker |
> \-------------------------------------------------------------------/
>
>
> XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
>
______________________________________________________________________________
Ferienklick.de - 225 Reisekataloge auf einen Blick!
Direkt zu Ihrem Traumurlaub: http://ferienklick.de/?PP=2-0-100-105-0
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list