Beefy Boxes and Bandwidth Generously Provided by pair Networks
Pathologically Eclectic Rubbish Lister
 
PerlMonks  

Re^3: sorting dates in YYYYMMDD format

by QM (Parson)
on Jul 10, 2013 at 09:10 UTC ( #1043428=note: print w/replies, xml ) Need Help??


in reply to Re^2: sorting dates in YYYYMMDD format
in thread sorting dates in YYYYMMDD format

One of the great things about YYYYMMDD is that if you sort it lexicographically you get it properly sorted!

Yes! This is what bugs me about all the international date "standards" -- none of them sort naturally. The only tweak I use is for human readability, YYYYMMmmmDD, where mmm is the 3 letter abbreviation (in the language of choice), which helps the mildly dyslexic distinguish 5 March and 3 May (though maybe that's the hardest one).

-QM
--
Quantum Mechanics: The dreams stuff is made of

Replies are listed 'Best First'.
Re^4: sorting dates in YYYYMMDD format
by Anonymous Monk on Jul 10, 2013 at 13:13 UTC
    Hos does a date in ISO 8601 format -- YYYY-MM-DDThh:mm:ss (and variations) -- does not sort correctly? Or, by "international date "standards"" did you mean something else?

      "Hos does a date in ISO 8601 format -- YYYY-MM-DDThh:mm:ss (and variations) -- does not sort correctly?" -- self.

      That horrible sentence should have been: "How do dates in ... -- YYYY-MM-DDThh:mm:ss (and variations) -- not sort correctly?".

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1043428]
help
Chatterbox?
[Corion]: If all else fails, Spreadsheet::XLSX should be "installable" by manually copying the files, provided that the prerequisites are met
[thezip]: It fails in the "formatted 2-digit numeric" tests
[thezip]: Okay Corion, that's what I wanted to hear. Thanks!
[Corion]: Oh, a test failure... Just force-install it then? --force and potentially --notest to skip the tests alltogether ?
[ambrus]: thezip: is Activestate Perl usable for your scenario instead?
[MidLifeXis]: Yeah, --notest is good, not sure I would do --force.
[thezip]: It fails 2/10 tests in that group. What are the ramifications if I force it? What should I look for for?
[thezip]: I've migrated from ActiveState to Strawberry. No going back...
[thezip]: I'll try the --notest arg first when I get back from meetings (after lunch).
[thezip]: Thanks guys for your comments! :-)

How do I use this? | Other CB clients
Other Users?
Others taking refuge in the Monastery: (13)
As of 2017-03-23 17:18 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    Should Pluto Get Its Planethood Back?



    Results (290 votes). Check out past polls.