Re: DISTINCT and COUNT help

From: Ludwig Lim <lud_nowhere_man(at)yahoo(dot)com>
To: Julie Keywell <julie(at)iparenting(dot)com>
Cc: pgsql-novice(at)postgresql(dot)org
Subject: Re: DISTINCT and COUNT help
Date: 2002-06-28 10:51:40
Message-ID: 20020628105140.13482.qmail@web40011.mail.yahoo.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-novice


Julie:

--- Julie Keywell <julie(at)iparenting(dot)com> wrote:
> Hi there!
>
> 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?

try SELECT COUNT(DISTINCT(<column name>))
FROM .....

ludwig

__________________________________________________
Do You Yahoo!?
LAUNCH - Your Yahoo! Music Experience
http://launch.yahoo.com

In response to

Browse pgsql-novice by date

  From Date Subject
Next Message Brian Johnson 2002-06-28 14:05:06 PostgreSQL setup on dual boot laptop
Previous Message Aarni Ruuhimäki / Megative Tmi / KYMI.com 2002-06-28 09:57:05 Parser function / command ?