On Thu, Mar 5, 2009 at 11:59 PM, Nico Grubert <nicogrub...@gmail.com> wrote:
>
>> 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())

The functionality is the same, since the now() will get rounded down
to the date with time of 00:00:00.  So, anytime for that day will be
>= to the output of date_trunc('day',now())

-- 
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general

Reply via email to