PC Review


Reply
Thread Tools Rate Thread

Count / Summary of a unique field.

 
 
kdaniel7979
Guest
Posts: n/a
 
      21st Feb 2006
I know this should be simple. But I just can't remember how to do this.

I just want to count the number of unique countries in a table.

i.e. Table
Field1=Name, Field2=Country

Dan, Canada
Steve, Canada
Dave, USA
Fred, England

I just want a query / Report to give me the results:

Countries = 3


This simple solution has eluded me for 30 minutes now.

Thx
Dan

 
Reply With Quote
 
 
 
 
=?Utf-8?B?a2FzYWI=?=
Guest
Posts: n/a
 
      21st Feb 2006
SELECT count(country) from Table;

You may have to GROUP BY country if more than 1 fields selected, but it is
not necessary for just one field.

(I had to look it up, too .. and I teach this stuff! )


"kdaniel7979" wrote:

> I know this should be simple. But I just can't remember how to do this.
>
> I just want to count the number of unique countries in a table.
>
> i.e. Table
> Field1=Name, Field2=Country
>
> Dan, Canada
> Steve, Canada
> Dave, USA
> Fred, England
>
> I just want a query / Report to give me the results:
>
> Countries = 3
>
>
> This simple solution has eluded me for 30 minutes now.
>
> Thx
> Dan
>
>

 
Reply With Quote
 
kdaniel7979
Guest
Posts: n/a
 
      21st Feb 2006
Thanks,
When I had a mutli field query it wasn't working, which is why I had
trouble figuring it out. Then after I created a very basic query it
worked fine.

Cheers

 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Y/N field in a query. How do I get report Summary to count Ys? =?Utf-8?B?TWF4UG93ZXI=?= Microsoft Access Reports 2 16th May 2007 05:05 PM
Count Unique Field Values Katherine Microsoft Access Queries 1 7th Jul 2006 05:40 PM
query unique count for field =?Utf-8?B?ZmxjMTIz?= Microsoft Access Queries 16 27th Jan 2006 10:28 AM
summary count of unique numbers =?Utf-8?B?RGF2ZSBFZGdl?= Microsoft Excel Misc 5 12th Nov 2005 12:06 AM
Get count of unique field values Ken Microsoft Excel Misc 3 1st Mar 2004 06:40 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 04:35 PM.