Hitachi Vantara Pentaho Community Forums
Results 1 to 4 of 4

Thread: epoch datetime conversion

  1. #1
    Join Date
    Aug 2007
    Posts
    8

    Default epoch datetime conversion

    Hi,
    A field I'm extracting is in Epoch time format. I would like to preserve the original field but, during transformation, convert it into a new field which has human readable time.

    Does anyone know how to do this?
    Thanks

  2. #2
    Join Date
    May 2006
    Posts
    4,882

    Default

    Use select values and change the meta data... example attached.

    Regards,
    Sven
    Attached Files Attached Files

  3. #3
    Join Date
    Aug 2007
    Posts
    8

    Default

    I tried running this but the conversion isn't correct. For example, the epoch time is 1170321248 translates to : January 31st, 2007 04:14:08 PM

    but using the Date conversion it is showing 1/14/1970 5:05:21 AM instead. Epoch time is the seconds, not milliseconds since 1970, could that be the problem?
    1/14/70 5:05 AM
    Wednesday, January 14, 1970

  4. #4
    Join Date
    May 2006
    Posts
    4,882

    Default

    True... divide by 1000 going one way, multiply by 1000 going the other.

    Regards,
    Sven

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Privacy Policy | Legal Notices | Safe Harbor Privacy Policy

Copyright © 2005 - 2019 Hitachi Vantara Corporation. All Rights Reserved.