[XSL-LIST Mailing List Archive Home] [By Thread] [By Date]

Re: [xsl] Sorting a TEI bibliography by

Subject: Re: [xsl] Sorting a TEI <biblStruct> bibliography by <surname>
From: "s.bauman@xxxxxxx" <xsl-list-service@xxxxxxxxxxxxxxxxxxxxxx>
Date: Mon, 21 Jul 2014 04:02:01 -0000

Short answer: use
instead of

The long answer would be better handled by someone more expert. And
to whatever extent I could give a long answer at all, I couldn't do
it when I'm this tired. :-)


> Thanks, Syd. You have identified the problem for me.  =20 Yes,
> there are some <biblStruct> entries in my data that contain=20 more
> than one <surname>. If I test this against entries that contain=20=

> only one <surname>, it works.  So I need to adjust my code such
> that it applies only to the *first* surname encountered.
> Thus, I changed
>   <xsl:sort select="*//surname"/>
> to
>   <xsl:sort select="*//surname[1]"/>
> but this generates the same error message.
> I need to find a way to select only the first occurrence of this 
> descendant. I am trying to figure this out now, but if anyone can 
> point me in the right direction, I'd be delighted!

Current Thread