[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] 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. Regards, Richard. > -----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
|
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
|