Re: how this query can be done?

From: Sybrand Bakker <postbus_at_sybrandb.demon.nl>
Date: 9 Apr 2002 00:20:31 -0700
Message-ID: <a20d28ee.0204082320.18b32566_at_posting.google.com>


"Henry" <hxzhang_at_binary-solutions.net> wrote in message news:<z8ss8.5923$KG3.353551_at_news2.telusplanet.net>...
> I have a table with different employees. It is known that employees may
> fall into the following categories:
>
> { type0, type1, type2, type3, ...type 100, ....}
>
> however, there could be no employ for a certain type at all.
>
> My boss wants an query that list all types with its number of employees.
> and the sql result will be like:
>
> type0 : 5 people
> type1 : 1 people
> type2 : 0 people
> ...
>
>
> how can i accomplish this?
> thanx a lot!

please refer to group by and count in your sql documentation, and try to resolve it yourself, you will learn from it. Otherwise: post the e-mail address of your boss, so we can send him to solution to this homework-question directly.

Regards

Sybrand Bakker
Senior Oracle DBA Received on Tue Apr 09 2002 - 09:20:31 CEST

Original text of this message