On Mon, Aug 03, 2009 at 11:15:25AM -0400, Bill Reynolds wrote:
> Here is what I am using in the from clause (along with other tables) to
> generate the series of numbers for the number of months. This seems to
> work:
> generate_series( 0, ((extract(years from age(current_date,
> DATE('2008-05-01'
Ok, it is Monday -:) Thanks Tom!
-Original Message-
From: Tom Lane [mailto:t...@sss.pgh.pa.us]
Sent: Monday, August 03, 2009 11:44 AM
To: Bill Reynolds
Cc: pgsql-general@postgresql.org
Subject: Re: [GENERAL] using generate_series to iterate through months
"Bill Reynolds&quo
Bill Reynolds wrote:
> Ok, I'm a bit stumped on getting my group by query to work which
> iterates through a number of months that basically a generate_series
> provides for me.
>
> Here is what I am using in the from clause (along with other tables) to
> generate the series of numbers for the n
"Bill Reynolds" writes:
> Ok, I'm a bit stumped on getting my group by query to work which
> iterates through a number of months that basically a generate_series
> provides for me.
> ...
> select DATE('2008-05-01') + interval (s.a??? ' months') as Month_of
No, you're confusing a syntax that's mea