Ascending and Descending by "frequency" in Sort


Issue raised by: Mahao [email protected] Thu, 17 Dec 1998 15:02:39 -0800 (GMT)


Synopsis:
What does "ascendingByFrequency" and "descendingByFrequency" (in sortRelation of SortKeySpec) mean?

Response:
"Ascending by frequency" (or "descending by frequency") is distinguished from "ascending" (or "descending") as illustrated in this example. Suppose we do a search on Moby Dick, get 6 hits and sort by author, ascending (conventionally ascending, i.e. not by frequency), and the resulting order is:
  1. Author: Bradbury, Ray
    Title: Moby Dick and that Bride of Time
  2. Author: Bradbury, Ray
    Title: Moby Dick and the Dandelion Wine
  3. Author: Herbert, T. Walter
    Title: Moby-Dick and Calvinism
  4. Author: Melville, Herman
    Title: Moby Dick : or, The whale : Paintings byLeRoy Neiman
  5. Author: Melville, Herman
    Title: Moby-Dick : or, The whale; Commentary by Howard Mumford Jones
  6. Author: Melville, Herman, 1819-1891.
    Title: Moby Dick : or, The whale; Introd. by A. S. W. Rosenbach.
If we do a "descending by frequency" sort, the order (of authors) would be Melville, Bradbury, Walker; because Melville had the highest frequency as author (3), Bradbury second (2), and Walker third (1). (Note that the ordering of items for a given author, e.g for the three Melville items, is determined by the server and cannot necessarily be predicted by the client.)

Status: Approved (3/99)
Library of Congress