Anonymous Monk has asked for the wisdom of the Perl Monks concerning the following question:

I have this date string: 2011-09-04T00:00:00

What DateTime::Format module would that open under?

I want to create a DateTime object straight from this string.

Replies are listed 'Best First'.
Re: What DateTime::Format?
by runrig (Abbot) on Sep 18, 2011 at 15:56 UTC
      The time zone is not optional with RFC3339. Gotta use looser ISO8601 instead.
Re: What DateTime::Format?
by CountZero (Bishop) on Sep 19, 2011 at 05:58 UTC
    When last I checked, none of the DateTime::Format modules would jump out of your computer and bite you when applied wrongly, so why don't you try them and see what works?

    Also reading their docs seems like a good idea.

    Have a look at DateTime::Format::DateParse, DateTime::Format::Flexible and DateTime::Format::Natural as well.

    CountZero

    A program should be light and agile, its subroutines connected like a string of pearls. The spirit and intent of the program should be retained throughout. There should be neither too little or too much, neither needless loops nor useless variables, neither lack of structure nor overwhelming rigidity." - The Tao of Programming, 4.1 - Geoffrey James