Path: news.easynews.com!newsfeed1.easynews.com!easynews.com!easynews!c03.atl99!news.webusenet.com!diablo.voicenet.com!proxad.net!news-hub.cableinet.net!blueyonder!cspc1n11e.baplc.com!lnewsfeed02.lnd.ops.eu.uu.net!lnewsifeed00.lnd.ops.eu.uu.net!lnewspost00.lnd.ops.eu.uu.net!emea.uu.net!not-for-mail
Newsgroups: comp.databases.oracle.server
From: Norman Dunbar <Norman.Dunbar@lfs.co.uk>
Subject: Specialised Counts
Message-ID: <E2F6A70FE45242488C865C3BC1245DA7038380D3@lnewton.leeds.lfs.co.uk>
Sender: Norman Dunbar <Norman.Dunbar@lfs.co.uk>
Date: Fri, 4 Apr 2003 11:48:30 +0100 
X-Newsreader: Microsoft (R) Exchange Internet News Service Version 5.5.2653.11
References: <8e45ea32.0304040202.b278dda@posting.google.com>
Lines: 50
NNTP-Posting-Host: mailhost3.lfs.co.uk
X-Trace: 1049453988 reading.news.pipex.net 21988 193.129.247.6
X-Complaints-To: abuse@uk.uu.net
Xref: newsfeed1.easynews.com comp.databases.oracle.server:181971
X-Received-Date: Fri, 04 Apr 2003 03:59:47 MST (news.easynews.com)

do you mean :

	select input, count(*) 
	from table
	group by input;

Assuming you are asking about a column in a table :o)

Cheers,
Norman.

-------------------------------------
Norman Dunbar
Database/Unix administrator
Lynx Financial Systems Ltd.
mailto:Norman.Dunbar@LFS.co.uk
Tel: 0113 289 6265
Fax: 0113 289 3146
URL: http://www.Lynx-FS.com
-------------------------------------


-----Original Message-----
From: markstarmer@hotmail.com (Mark Starmer)
[mailto:markstarmer@hotmail.com]
Posted At: Friday, April 04, 2003 11:02 AM
Posted To: server
Conversation: Specialised Counts
Subject: Specialised Counts


Is there a way (perhaps using nested SQL) to count the number of
occurances of each distinct record ie

Input
-----
John
John
John
Jim

Output
------
John - 3
Jim -1 

Thanks a lot

M Starmer

