Custom Date Format

Constructing a Custom Date Format String

When you import data into Analytics Plus (from CSV, XLS, HTML etc., files) and if the data contains date values, Analytics Plus tries to auto identify the existence of a date column based on the values provided. Users can also select the required date column format from the default list provided, or provide a custom date format string to match with the date column being imported. This section provides instructions on constructing a custom date format string.

Reference Table

The following table captures all the date format strings (or abbreviations) and their meanings. Special characters (slash, comma, etc.) can also be included as part of the format strings.

Format String

Meaning

Example

yyIndicates Year value without century.
If the value is from 70 to 99, year is assumed as 20th century (1970, 1971... 1999).
Anything other than this is considered as the 21st century.
14 (means 2019),
08 (means 2008).
yyyyIndicates Year value with century.2019
MMIndicates Month value in numeric format.3 (means March),
11 (means November).
MMMIndicates Month value as a 3 letter string abbreviation.Jan, Feb
MMMMIndicates Month value in full string.January, February
ddIndicates the Day of the month.12, 30
EEEIndicates the Day in the week (abbreviation).Wed, Sun
EEEEIndicates Day in the week (full string form).Wednesday, Sunday
HHIndicates Hours in a day, between 0 and 23 hrs.13:50, 20:20
hhIndicates Hours in a day, between 1 to 12 hrs (morning and afternoon is identified by AM and PM).1:30, 11:30
mmIndicates the Minutes in an hour.1:30
ssIndicates the Seconds in a minute11:30:30
SSSIndicates the Millisecond in the Date.11:30:30.163
aIndicates AM/PM of the time11:00 am, 2:00 pm
zIndicates the Time zone based on either GMT or country specific time zone abbreviation.Nov 24, 2018 10:00 pm GMT +5:30
Nov 24, 2018 10:00 pm PST
ZIndicates the Time zone based on RFC 822 standard.Nov 24, 2018 +0530
Nov 24, 2018 -0247
MILLIIndicates number of milliseconds since January 1, 1970.911899079000

Examples

 1Date: 11/24/2018
Format String to be given: MM/dd/yyyy
  11MMIndicates the month.
 24ddIndicates the day.
 2018yyyIndicates the year.
2Date: 11.24.2018
Format String to be given: MM.dd.yyyy
 11MMIndicates the month.
24ddIndicates the day.
2018 yyyIndicates the year.
3Date: Nov 24, 2018 02:47 PM
Format String to be given: MMM dd, yyyy hh:mm a
 NovMMMIndicates the month.
24ddIndicates the day.
2018yyyIndicates the year.
02hhIndicates the hour (01-12).
47mmIndicates the minute.
PMaIndicates the AM/PM.
4Date: Nov 24, 2018 14:47
Format String to be given: MMM dd, yyyy HH:mm
 NovMMMIndicates the month.
24ddIndicates the day.
2018yyyIndicates the year.
02hhIndicates the hour (01-12).
47mmIndicates the minute.
PMaIndicates the AM/PM.
 
5Date: 11/24/2018
Format String to be given: MM/dd/yyyy
 11MMIndicates the month.
24ddIndicates the day.
2018yyyIndicates the year.
6Date: Nov 24, 2018 02:47 PM GMT +5:30
Format String to be given: MMM dd, yyyy hh:mm a z
 NovMMMIndicates the month.
24ddIndicates the day.
2018yyyIndicates the year.
02hhIndicates the hour (01-12).
47mmIndicates the minute.
PMaIndicates the AM/PM.
 
 GMT +5:30zIndicates the time zone.
7Date: Nov 24, 2018 02:47 PM PST
Format String to be given: MMM dd, yyyy hh:mm a z
 NovMMMIndicates the month.
24ddIndicates the day.
2018yyyIndicates the year.
02hhIndicates the hour (01-12).
47mmIndicates the minute.
PMaIndicates the AM/PM.
 
 PSTzIndicates the time zone.
8Date: Wednesday, 24-Nov-98 14:47:59.163
Format String to be given: EEEE, dd-MMM-yy HH:mm:ss.SSS
 WednesdayEEEEIndicates the weekday.
 24ddIndicates the day.
 NovMMMIndicates the month.
98yyIndicates the year.
14HHIndicates the hour (00-23).
47mmIndicates the minute.
69ssIndicates the second.
163SSSIndicates the millisecond.

Share this post : FacebookTwitter