Skip to main content

Description

Parses common date string formats and returns an ISO 8601 date (YYYY-MM-DD). Use it to standardize date values from mixed sources before storing, sorting, or joining on date. Accepted input formats:
  • ISO date: 2026-05-22
  • Slash or dash US-style: 05/22/2026, 5/2/2026, 05-22-2026
  • English month names (case-insensitive): May 22, 2026, 22 May 2026
  • Datetime values, from which the date portion is extracted: 2026-05-22T10:00:00, 2026-05-27T17:57:44Z, 2026-05-27T17:57:44+05:00, 2026-05-27 17:57:44.123
For datetime inputs that include a timezone offset, NormalizeDate returns the date as written and performs no timezone conversion. NormalizeDate('2026-05-27T01:00:00+12:00') returns 2026-05-27, not 2026-05-26. The function uses strict date resolution, so silently-adjusted values such as Feb 30 are rejected rather than rolled forward.

Syntax

NormalizeDate(string_expression[, locale_tag]) The optional locale_tag controls how ambiguous numeric formats are interpreted. It is case-insensitive.
Locale tagBehavior
US (default)Month/day/year for numeric formats (05/22/2026 is May 22).
EUDay/month/year for numeric formats (01/02/2026 is February 1).
ISOOnly accepts unambiguous formats. Rejects NN/NN/YYYY but accepts datetime forms.

Examples

NormalizeDate('May 22, 2026') returns '2026-05-22'. NormalizeDate('05/22/2026') returns '2026-05-22'. NormalizeDate('01/02/2026', 'EU') returns '2026-02-01'. NormalizeDate('2026-05-27T17:57:44Z') returns '2026-05-27'. NormalizeDate('2026-05-27T01:00:00+12:00') returns '2026-05-27'.

Return value datatype

String

Impact of null value

Returns null for any of the following:
  • Null, empty, or whitespace-only input
  • Invalid calendar dates (Feb 30, month 13, non-leap Feb 29)
  • Invalid time components in datetime inputs (hour 25, minute 60)
  • 2-digit years
  • Unknown locale tags
Last modified on May 28, 2026