How to convert long/milliseconds to DateTime?

Discussion in 'Ruby' started by Mike Nospam, Oct 24, 2006.

  1. Mike Nospam

    Mike Nospam Guest

    Hi,

    Java developer making the switch. I have timestamps stored in Oracle as
    a long (gotten from java.sql.Timestamp - milliseconds from some day in
    1970). Is there a way to convert that long back into a Ruby
    Date/DateTime/Time . Any of these would do.

    Did not find a method in the library...

    Thanks,

    Mike

    --
    Posted via http://www.ruby-forum.com/.
    Mike Nospam, Oct 24, 2006
    #1
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Christos TZOTZIOY Georgiou
    Replies:
    3
    Views:
    686
    Christos TZOTZIOY Georgiou
    Sep 13, 2003
  2. Tim Peters
    Replies:
    0
    Views:
    520
    Tim Peters
    Sep 9, 2003
  3. mp
    Replies:
    1
    Views:
    374
    John Machin
    Jul 28, 2006
  4. Martin
    Replies:
    0
    Views:
    328
    Martin
    Dec 27, 2008
  5. Replies:
    2
    Views:
    744
    M.-A. Lemburg
    Jan 6, 2009
Loading...

Share This Page