Re: DISTINCT and COUNT help - Mailing list pgsql-novice

From Manfred Koizar
Subject Re: DISTINCT and COUNT help
Date
Msg-id e2aohusr05gfipui4m467mii23au3pc48e@4ax.com
Whole thread Raw
In response to DISTINCT and COUNT help  (Julie Keywell <julie@iparenting.com>)
List pgsql-novice
On Fri, 28 Jun 2002 00:10:56 -0500, Julie Keywell <julie@iparenting.com> wrote:
>I would like to count the number of distinct values in a column.  Is
>there any way to combine DISTINCT and COUNT and if so, what is the
>syntax?
Julie, it's so obvious, you didn't dare to think of it :-)

SELECT COUNT(DISTINCT col) FROM t;

Servus
 Manfred



pgsql-novice by date:

Previous
From: Chris
Date:
Subject: Re: DISTINCT and COUNT help
Next
From: AarniRuuhimäki / Megative Tmi / KYMI.com
Date:
Subject: Parser function / command ?