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

Re: few question regarding the use of id generation

Subject: Re: few question regarding the use of id generation
From: "Joerg Heinicke" <joerg.heinicke@xxxxxx>
Date: Wed, 6 Feb 2002 01:24:12 +0100
few question
Hi William,

you can use the grouping via Muenchian Method too (see the list today).
Group your c by it's values:

<xsl:key name="c-values" match="c" use="text()"/>

<xsl:template match="/">
    <xsl:apply-templates select="descendant::c[count( . | key('c-values',
text())[1] = 1]"/>
</xsl:template>

<xsl:template match="c">
    <!-- Now you have unique <c>s or you can create an id. -->
</xsl:template>

Regards,

Joerg

----- Original Message -----
From: "林 子芯" <minikittygo@xxxxxxxxxxx>
To: <xsl-list@xxxxxxxxxxxxxxxxxxxxxx>
Sent: Tuesday, February 05, 2002 7:32 PM
Subject: RE:  few question regarding the use of id generation


> I here to thank Andrew and Joerg for the advice, however, going back to my
> first question i was hoping to generate the an unique id for the same c
> elements (when i said the same, i mean the value within the c element are
> identical, not the location of the c element i.e.
> <b>
>    <c id="NA12">1</c>
> </b>
> <d>
>    <c id="NA12">1</c>
> </d>
> <e>
>    < id="NBS3">2</c>
> </e>
> this is need as i could create a table that will only display the item
with
> the given ID.
>
> i was wondering is there are ways to do so?
>
> whilst i am it, can i just asked when i need to perform a merge operation,
> do i have to re-enter the xml tags? is all the tags in the xml are strip?
> if yes, is there are ways to overcome this?
>
> thanks for the advice
>
> Regards
> William


 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.