Re: Substring selection anyone?
Hello David, would the translation to uppercase solve your problem? Something like this: test = "value/text[translate(substring(., 0, 4),'abcdefghijklmnopqrstuvwxyz','ABCDEFGHIJKLMNOPQRSTUVWXYZ') = $key]" where $key is only uppercase, e.g. "NAME" Best regards Jirka David Rigby wrote: > > Does anyone have any idea if there's a way to include a case insensitive > substring comparison in an xpath predicate? What I'd like is something of > the form: > > <xsl:apply-templates select="value/text[$key = <NO > CASE!!>substring(value/text, 0, 4)] "/> > > ...assuming $key is a simple string containing the search key > > I don't know of any way to manage the case insensitive aspect. > > I'd be grateful for any assistance! > > Thanks > > David > > Knowledge Support Systems Limited > A division of Knowledge Support Systems Group plc > Seventh Floor St James's Buildings 79 Oxford Street Manchester M1 6SS England > Company Registration Number 2800886 (Limited) 3449594 (plc) > Tel: +44 (0) 161 228 0040 Fax: +44 (0) 161 236 6305 > mailto:kssg@xxxxxxxx http://www.kssg.com > > The information in this Internet email is confidential and may be legally privileged. It is intended solely for the addressee(s). Access to this Internet email by anyone else is unauthorised. > > If you are not the intended recipient, any disclosure, copying, distribution or any action taken or omitted to be taken in reliance on it, is prohibited and may be unlawful. When addressed to our clients any opinions or advice contained in this Internet email are subject to the terms and conditions expressed in the governing engagement letter or contract. > > This email message and any attached files have been scanned for the presence of computer viruses. However you are advised that you open any attachments at your own risk. > > XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list -- <name firstName="Jirka" surname="Jirat"/> <mail> jiratj@xxxxxxxxx </mail> <support> http://www.zvon.org </support> <zvonMailingList> http://www.zvon.org/index.php?nav_id=4 </zvonMailingList> 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