bquirion@gmail.com wrote:
> foodb=> select date_trunc('week', now() - interval '1 week');
> date_trunc
> ------------------------
> 2013-12-30 00:00:00-08
> (1 row)
>
> foodb=> select date_trunc('week', now() - interval '2 week');
> date_trunc
> ------------------------
> 2014-12-22 00:00:00-08
> (1 row)
>
> I'mn using postgres 8.0.3
8.0.3 was released in 2005. The latest in the 8.0 branch, 8.0.26 was
released in 2010 containing about 600 commits with bug fixes. At the
very least you should update to that version and see if it fixes the
problem you have. In any case you're running a version that has been
out of support for five years now.
--
Álvaro Herrera http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services