Carol Cheung wrote:
> Hi,
> I have a table called temp
>
> access_date | active | status
> -++
> 2009-02-01 | t | 15
> 2009-02-01 | f | 16
> 2009-02-02 | f | 17
> 2009-02-01 | t | 17
> 2009-02-02 | f | 21
> 2009-
Carol Cheung writes:
> I tried something like
> SELECT to_char(access_date, 'MM') as year_month, count(year_month)
> FROM temp GROUP BY year_month ORDER BY year_month;
The only problem in what you wrote was the illegal cross-reference
from one output column to another. Just use count(*) ins
On Fri, Feb 27, 2009 at 2:02 PM, Carol Cheung
wrote:
> Hi,
> I have a table called temp
>
> access_date | active | status
> -++
> 2009-02-01 | t | 15
> 2009-02-01 | f | 16
> 2009-02-02 | f | 17
> 2009-02-01 | t | 17
> 2009-0
Hi,
I have a table called temp
access_date | active | status
-++
2009-02-01 | t | 15
2009-02-01 | f | 16
2009-02-02 | f | 17
2009-02-01 | t | 17
2009-02-02 | f | 21
2009-01-01 | t | 20
2009-01-01 | t