Re: After Upgrade from 8.2.6 to 8.3.6: function to_timestamp does not exist

From: "Adam Rich" <adam(dot)r(at)sbcglobal(dot)net>
To: "'Nico Grubert'" <nicogrubert(at)gmail(dot)com>, "'Scott Marlowe'" <scott(dot)marlowe(at)gmail(dot)com>
Cc: <pgsql-general(at)postgresql(dot)org>
Subject: Re: After Upgrade from 8.2.6 to 8.3.6: function to_timestamp does not exist
Date: 2009-03-06 07:04:51
Message-ID: 011401c99e29$d8bd4460$8a37cd20$@r@sbcglobal.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

>
>
> > OK, so you want to see if a timestamp is greater than now()? Why not
> > just compare them?
> >
> > where a.from_datetime >= now()
>
> No, not the whole timestamp. I dont want to check the time.
> So I had to truncate the datetime with:
>
> date_trunc('day', a.from_datetime) >= date_trunc('day', NOW())
>

If you're going to truncate the NOW(), just go with CURRENT_DATE instead.

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Scott Marlowe 2009-03-06 07:07:00 Re: Performance of subselects
Previous Message Adam Rich 2009-03-06 07:03:22 Re: After Upgrade from 8.2.6 to 8.3.6: function to_timestamp does not exist