<< Click to Display Table of Contents >> Navigation: Reference > Transforms > Date Format |
Changes the date format in one or more columns.
Change day/month/year to month-day-year:
One.
•Check the columns you wish to transform.
•Supply the existing date format in Format from (see below).
•Supply the new date format in Format to (see below).
•The following date formats are supported for input and output:
Format |
Meaning |
---|---|
d |
The day as number without a leading zero (1 to 31) |
dd |
The day as number with a leading zero (01 to 31) |
ddd |
The abbreviated localized day name (e.g. 'Mon' to 'Sun'). Uses the locale to localize the name. |
dddd |
The long localized day name (e.g. 'Monday' to 'Sunday'). Uses the locale to localize the name. |
M |
The month as number without a leading zero (1 to 12). |
MM |
The month as number with a leading zero (01 to 12) |
MMM |
The abbreviated localized month name (e.g. 'Jan' to 'Dec'). Uses the locale to localize the name. |
MMMM |
The long localized month name (e.g. 'January' to 'December'). Uses the locale to localize the name. |
yy |
The year as a two digit number (00 to 99). |
yyyy |
The year as a four digit number. If the year is negative, a minus sign is prepended in addition. |
•An exact match is expected for the input date. E.g. Format from is yyyy-MM-dd then 2020-12-17 will be converted, but 2020-12-17T14:58 won't. You can extract just the date part here using Split Col with T as the delimiter.
•Use the correct case for the format (e.g. yyyy-MM-dd, not YYYY-mm-DD).
•The Locale set in the Preferences window is used to decide how the date is represented (e.g. names of months and days).
•You can also use Split Col to split a date into its component parts. For example to split "31/1/2019" into day, month and year components using the "/" delimiter.
•If the date to be converted has only two year digits, it is treated as a date between 1900 and 1999. E.g. "31/1/19" is interpreted in d-M-yy format as 31st January 1919.
•Warnings are shown in the Warnings tab for values that don't match Format from.