From: | "D(dot) Duccini" <duccini(at)backpack(dot)com> |
---|---|
To: | Frank Bax <fbax(at)execulink(dot)com> |
Cc: | Pgsql-novice <pgsql-novice(at)postgreSQL(dot)org> |
Subject: | Re: how to cast for dates/datetimes? |
Date: | 2000-08-22 14:05:50 |
Message-ID: | Pine.GSO.4.03.10008220904310.12957-100000@ra.bpsi.net |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-novice |
> I suspect that your calculation yeilds a timestamp instead of date because
> 'now' is a timestamp, not a date, try:
>
> select sum(total) from lineitemsnext where date <= ('now'::date + '1
> month'::timespan)::date;
This one did the trick. I'll try the other variants later on.
Thanks!
-duck
-----------------------------------------------------------------------------
david(at)backpack(dot)com BackPack Software, Inc. www.backpack.com
+1 651.645.7550 voice "Life is an Adventure.
+1 651.645.9798 fax Don't forget your BackPack!"
-----------------------------------------------------------------------------
From | Date | Subject | |
---|---|---|---|
Next Message | Ryan Williams | 2000-08-22 17:16:22 | Unsigned? |
Previous Message | Dave_Pfaltzgraff | 2000-08-22 12:03:52 | Re: how to cast for dates/datetimes? |