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

RE: date sorting with internationalisation

Subject: RE: date sorting with internationalisation
From: "Kerry, Richard" <richard.kerry@xxxxxxxxxxx>
Date: Thu, 17 Dec 2009 12:54:05 +0100
RE:  date sorting with internationalisation
Convert the date, whatever format it starts in, into YYYYMMDDHHMMSS.
(MM (month) being numeric)

Then you can just use text sort on it.  Not needing to worry about
punctuation, or splitting into separate parts.


> -----Original Message-----
> From: Anil Kumar Veeramalli [mailto:anil.v@xxxxxxxxxxxxxxxxxxxxx]
> Sent: 17 December 2009 09:56
> To: xsl-list@xxxxxxxxxxxxxxxxxxxxxx
> Subject:  date sorting with internationalisation
> Hi ,
> I am using XSL1.0 version. currently I am sorting the date
> elements like
> this.
> my current date format is dd-MMM-yyyy HH:mm:ss.
>  <xsl:sort
> select="substring-after(substring-after(substring(COLUMN[@NAME
> ='N_DT_EFF'],1,12),'-'),'-')"
> data-type="number"/>
>  <xsl:sort
> select="string-length(substring-before($vMonthNames,substring-
> before(substring-after(substring(COLUMN[@NAME='N_DT_EFF'],1,12
> ),'-'),'-')))"
> data-type="number"/>
>  <xsl:sort
> select="substring-before(substring(COLUMN[@NAME='N_DT_EFF'],1,
> 12),'-')"
> data-type="number"/>
> Now I want to support the same with French Language. in
> French my date
> format is looking like this  01-janv.-1900.
> what is the better way to sort French Dates.
> Thanks,
> Anil

Current Thread


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.
First Name
Last Name
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.