Modify

Opened 7 weeks ago

Last modified 7 weeks ago

#3724 new Feature Request

_DateTimeSplit should ignore trailing Z (to accept parsing RFC3339 formated date time)

Reported by: matwachich@… Owned by:
Milestone: Component: Standard UDFs
Version: Severity: None
Keywords: _DateTimeSplit RFC3339 Cc:

Description

When passing a RFC3339 formated date-time string to _DateTimeSplit, the seconds are ignored.

_DateTimeSplit("2019-03-07T20:31:30Z", $aDate, $aTime)
Returns correct $aDate, but $aTime[3] = 0

Solutions:

  • StringLeft($sDateTime, 19)
  • Or make a more complete function that will completely support RFC3339 date-time (with miliseconds/nanoseconds...)

Attachments (0)

Change History (3)

comment:1 Changed 7 weeks ago by Jos

  • Type changed from Bug to Feature Request

This can't be a BUG as the supported formats are clearly defined in the Helpfile.
Change it to a feature request.

Jos

comment:2 Changed 7 weeks ago by TicketCleanup

  • Version 3.3.14.5 deleted

Automatic ticket cleanup.

comment:3 Changed 7 weeks ago by jchd18

Modifying the various date/time functions for full compliance to the RFC would be a huge and difficult task leading to a number of script-breaking changes. Rigourous handling of timestamps is populated by hords of venimous worms, whatever language you use.

If your application requires handling anything not covered by the current simple implementation, I'd advise to write a UDF covering a wider range of formats.

Guidelines for posting comments:

  • You cannot re-open a ticket but you may still leave a comment if you have additional information to add.
  • In-depth discussions should take place on the forum.

For more information see the full version of the ticket guidelines here.

Add Comment

Modify Ticket

Action
as new The ticket will remain with no owner.
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.