Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 Other Forums
 MS Access
 COUNT(DISTINCT [COL])

Author  Topic 

X002548
Not Just a Number

15586 Posts

Posted - 2003-03-24 : 15:59:59
You can't do this in Access? How do you get a count of distinct values then?


Brett

8-)

jsmith8858
Dr. Cross Join

7423 Posts

Posted - 2003-03-24 : 16:02:56
You need two steps in Access.

First, do a GROUP BY the field you want and save it as query1. Then do a query of query1, with a COUNT() of the same field.


- Jeff
Go to Top of Page

X002548
Not Just a Number

15586 Posts

Posted - 2003-03-25 : 08:52:44
Did I mention I hate (but invariabley have to use) Access.

Thanks Jeff



Brett

8-)
Go to Top of Page

jsmith8858
Dr. Cross Join

7423 Posts

Posted - 2003-03-25 : 09:09:11
It's not THAT bad ...

It does have a nice report writer and makes rapid application development really easy ... and for all of it's faults, the JET engine does a good job of combining multiple datasources very easily (and usually quite efficiently) using linked tables.

Here's my analogy:

Access is like a microwave oven. Don't use it to prepare your entire meal or rely on it completely, but it can be a very useful tool to complement your stove, oven and grill. And it can get results pretty darn quickly.

how's that one??


- Jeff
Go to Top of Page

X002548
Not Just a Number

15586 Posts

Posted - 2003-03-25 : 13:20:44
Good one...yeah, I use it often in a veru=y utilitarian manner. I caution (but who listens) not to use it for multi-user applications. And yes, it's hard to beat it's reporting and data centralization.

Oh, and a good proto-typer as well.

Microwave indeed!


Brett

8-)
Go to Top of Page
   

- Advertisement -