My Assistant
![]() ![]() |
|
|
Jan 23 2006, 11:35 PM
Post
#1
|
|
|
UtterAccess Addict Posts: 121 From: USA (the best) |
I am making a member database, in which I created a report to count all the members, but it won't count more than 99 members. Below is the code I used:
=Count([MemberID]) Also, I have records with the same FirstName and lastName, and the record works fine when I pull them up sorted by memberID, but when I try to sort them by last name, it doesnt allow duplicates. Any ideas anyone? Thanks |
|
|
|
Jan 24 2006, 12:55 AM
Post
#2
|
|
|
UtterAccess Enthusiast Posts: 53 |
Try basing your count on a query like this: select count(*) as Members from tblMembers. You may have to massage the SQL a bit if your back-end database is Access. The above will work on SQL Server. The "order by" statement seems to return a set, from what you say. A set allows no duplicates. make it "sort by lastName, MemberID" and try only to display the lastName and see what that does.
|
|
|
|
Jan 24 2006, 12:59 AM
Post
#3
|
|
|
UtterAccess Enthusiast Posts: 53 |
A quick PS to the posting above: did you use "select DISTINCT lastName" or just "select lastName"? That would explain the absence of duplicates.
|
|
|
|
![]() ![]() |
|
Go to Top · Lo-Fi Version | Time is now: 22nd May 2013 - 04:25 PM |