Page tree

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Published by Scroll Versions from space DEV and version next

D toc
 

Excerpt

Formats a set of Unix timestamps according to a specified date formatting string.  

Source values can be a reference to a column containing Unix timestamp values.

...

DescriptionunixTimestamp columnTransformnewUnixTimestamp column
Numeric date, year first

1454946120000

1451433600000

1430032020000

D code

derive type:single value:UNIXTIMEFORMAT(unixTimestamp,'yyyy-MM-dd') as:'newUnixTimestamp'

2016-02-08

2015-12-30

2015-04-26

Numeric date, American style

1454946120000

1451433600000

1430032020000

D code

derive type:single value:UNIXTIMEFORMAT(unixTimestamp,'M/d/yy') as:'newUnixTimestamp'

2/8/16

12/30/15

4/26/15

Full written date

1454946120000

1451433600000

1430032020000

D code

derive type:single value:UNIXTIMEFORMAT(unixTimestamp,'MMMM dd, yyyy') as:'newUnixTimestamp'

February 08, 2016

December 30, 2015

April 26, 2015

Abbreviated date,
including abbreviated
day of week

1454946120000

1451433600000

1430032020000

D code

derive type:single value:UNIXTIMEFORMAT(unixTimestamp,'EEE MMM dd, yyyy') as:'newUnixTimestamp'

Mon Feb 08, 2016

Wed Dec 30, 2015

Sun Apr 26, 2015

Full 24-hour time

1454946120000

1451433600000

1430032020000

D code

derive type:single value:UNIXTIMEFORMAT(unixTimestamp,'HH:mm:ss.SSS') as:'newUnixTimestamp'

15:42:00.000

00:00:00.000

07:07:00.00

Twelve-hour time with AM/PM indicator

1454946120000

1451433600000

1430032020000

D code

derive type:single value:UNIXTIMEFORMAT(unixTimestamp,'h:mm:ss a') as:'newUnixTimestamp'

Info

NOTE: For this function, use of the lower-case hour indicator (h or hh) requires the use of an AM/PM indicator (a).

3:42:00 PM

12:00:00 AM

7:07:00 AM

D s also
labeldate