View Full Version : ranking POSITION BY CATEGORY


hootie318
01-15-2009, 10:19 AM
I am not sure how to explain this, but here it goes. I have a sales report with three major categories for each salesperson. I am ranking the salespeople in each category. Is there a way add a field that ranks salesperson by category.

Salesperson Dollars Rank SalesCount Rank Warranties Rank
John 1200 1 271 3 35 3
Beth 1100 2 284 1 36 2
Frank 1000 3 275 2 42 1

pbaldy
01-15-2009, 10:26 AM
I would think the same way you'd do a single ranking. Either a DCount() or subquery for each category that counted the number of people >= the current record.

hootie318
01-15-2009, 11:45 AM
I dont know how to do that. I will do some searching.

pbaldy
01-15-2009, 11:50 AM
Searching on ranking should turn up the methods. I know they're in the MS sample queries. Post back if you don't find them.