postgres UTC different from perl?

From: Louis-David Mitterrand <vindex+lists-pgsql-general(at)apartia(dot)org>
To: pgsql-general(at)postgresql(dot)org
Subject: postgres UTC different from perl?
Date: 2007-12-19 19:31:32
Message-ID: 20071219193128.GA13328@apartia.fr
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Hi,

when trying:

psql template1 -c "select date_part('epoch',current_date at time zone 'UTC');"
date_part
------------
1198015200

the result is different from

perl -MDateTime -le 'print DateTime->today(time_zone => "UTC")->epoch;'
1198022400

Is there an issue with postgresql?

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Reg Me Please 2007-12-19 19:53:04 Rich LIKE inheritance
Previous Message Matt Magoffin 2007-12-19 19:16:52 Re: Way to avoid expensive Recheck Cond in index lookup?