tracker issue : CF-3700851

select a category, or use search below
(searches all categories and all time range)

parseDateTime() should deal with ISO-formatted dates

| View in Tracker

Status/Resolution/Reason: Closed/Fixed/

Reporter/Name(from Bugbase): Adam Cameron / Adam Cameron (Adam Cameron)

Created: 01/29/2014

Components: Language

Versions: 10.0

Failure Type:

Found In Build/Fixed In Build: Final / 289002

Priority/Frequency: Major / Most users will encounter

Locale/System: English / Platforms All

Vote Count: 1


parseDateTime() should parse ISO-formatted dat/time strings.


----------------------------- Additional Watson Details -----------------------------

Watson Bug ID:	3700851

External Customer Info:
External Company:  
External Customer Name: Adam Cameron.
External Customer Email:  
External Test Config: My Hardware and Environment details:



seems reasonable to me! (and this 25 character minimum for votes is just stupid)
Vote by External U.
13581 | January 29, 2014 08:48:45 AM GMT
You can always specify the format in ParseDateTime or LSParseDateTime. So your example would look like parseDateTime("1997-07-16T19:20:30+01:00", "yyyy-MM-dd'T'HH:mm:ssX"); IMO, we should not do anything more here.
Comment by Rupesh K.
13574 | February 04, 2014 06:50:29 AM GMT
I think you need to update/fix your docs. There is no mention of the format string for parseDateTime(): That said, I disagree with you here. Out of any possible format one might potentially use, **ISO** formats should "just work". Given they are the industry standards. I should not have to provide a mask to you so you understand what an ISO-formatted date is. What do you think? -- Adam
Comment by External U.
13575 | February 04, 2014 07:07:12 AM GMT
Sorry, forgot to say: "cheers for the heads-up re the format string!" I asked for this enhancement request a coupla weeks back... not knowing it was already there... You can close that one! -- Adam
Comment by External U.
13576 | February 04, 2014 07:13:22 AM GMT
Makes sense. Probably what we can do is - if the default parsing fails, we can try to parse it as ISO date.
Comment by Rupesh K.
13577 | February 04, 2014 09:57:27 AM GMT
I think that'd be OK in situations where there is no mask specified. That'd be OK for backwards compat too, I think. Just to be clear, if there IS a format mask specified, ONLY that pattern is used, right? -- Adam
Comment by External U.
13578 | February 04, 2014 10:01:58 AM GMT
of course!
Comment by Rupesh K.
13579 | February 04, 2014 10:04:07 AM GMT
Comment by External U.
13580 | February 04, 2014 10:05:17 AM GMT