Date::Calc and postgres timestamp

Discussion in 'Perl Misc' started by jeff_jones_101@yahoo.com, Dec 27, 2006.

  1. Guest

    Dear all,

    I'd little a little hint on date comparison using Date::Cal module.

    I take the first date from a postgres db where the field is declared
    as:
    created | timestamp(6) without time zone |
    Selecting through DBI I receive a date in the form of
    2006-12-14 16:08:39

    The second one is a a Date::Calc

    my ($y,$m,$d,$H,$M,$S) = Add_Delta_DHMS(Today_and_Now(),120,0,0,0);

    I grasp a bit in Date:Calc documentation but I've not found a way to
    convert the first in a delta vector, which I think it is the only way
    Date:Calc could compare the the two dates.

    How can I compare these two date type ?

    Thanks
     
    , Dec 27, 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. Marc
    Replies:
    0
    Views:
    120
  2. Nick Black
    Replies:
    1
    Views:
    169
    Kashia Buch
    Nov 16, 2006
  3. Kaye Ng

    ruby calc.rb or just calc.rb

    Kaye Ng, Jul 26, 2010, in forum: Ruby
    Replies:
    7
    Views:
    410
    Kaye Ng
    Jul 28, 2010
  4. Leendert Bottelberghs

    update: timezone offset calc and date formatting

    Leendert Bottelberghs, Apr 8, 2005, in forum: Perl Misc
    Replies:
    0
    Views:
    203
    Leendert Bottelberghs
    Apr 8, 2005
  5. Bob
    Replies:
    1
    Views:
    288
    Paul Lalli
    Sep 1, 2005
Loading...

Share This Page