ACC: How to Rank Records Within a Query (120608)
The information in this article applies to:
- Microsoft Access 2.0
- Microsoft Access for Windows 95 7.0
- Microsoft Access 97
This article was previously published under Q120608 SUMMARY
Advanced: Requires expert coding, interoperability, and multiuser skills.
This article has three examples that show you how to rank records
within a query. The first example ranks records from a table. The second
example ranks the results of a totals query. The third example demonstrates
an alternative method of handling ties in ranking.
All the examples in this article require a field containing a value that
can be evaluated using either the GREATER THAN (>) or the LESS THAN (<)
operator, and a subquery to count the number of records that are greater
than or less than the current record.
NOTE: A demonstration of the technique used in this article can be seen
in the sample file, Qrysmp97.exe. For information about how to obtain
this sample file, please see the following article in the Microsoft
Knowledge Base:
182568 ACC97: Microsoft Access 97 Sample Queries Available in Download Center
Modification Type: | Major | Last Reviewed: | 5/6/2003 |
---|
Keywords: | kbhowto KB120608 |
---|
|