Special Date/Time Inputs

From: Tomasz Myrta <jasiek(at)klaster(dot)net>
To: "'pgsql-sql(at)postgresql(dot)org'" <pgsql-sql(at)postgresql(dot)org>
Subject: Special Date/Time Inputs
Date: 2003-02-17 10:53:06
Message-ID: 3E50BF12.4020909@klaster.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql

Hi
How do you use Special Date/Time Inputs described in Table 5.14
(Postgresql documentation)?
It looks like only now() works. When I try to select epoch() I get
error, that such function doesn't exist.

Anyway it came from another problem:
I have table with millions records indexed on timestamp. I tried to
speed up using this table, so I changed timestamp into
seconds-since-epoch (integer). What do you think about it?
Is there a better way to convert this field back into timestamp than
'1970-01-01'::timestamp+cast(field || ' seconds' as interval) ?

Regards,
Tomasz Myrta

Responses

Browse pgsql-sql by date

  From Date Subject
Next Message A.Bhuvaneswaran 2003-02-17 12:12:04 Re: Special Date/Time Inputs
Previous Message betty 2003-02-17 10:25:54 Re: trigger after with cursor