DATE_PARSE function


DATE_PARSE takes a string or integer representing a date, parses it according to a provided format and timezone, then returns an object with a variety of useful information, including:

  • Integer representations of the year, month, day of the month, day of the week, hour, minute, second, and millisecond

  • Name of the month, day, and timezone

  • ISO8601 and unix timestamp representations of the date

This object can be passed to DATE.

If the parse format argument isn't provided, it will attempt to guess the format, but explicit formats can be used to reliably parse ambiguous dates like 01/02/2023, which is January 2nd in EU-format and February 1st in US-format.