Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Dual Fields in Indexes

Status
Not open for further replies.

cssiii2000

Technical User
Dec 11, 2000
1
0
0
US
the logic of MS at time illudes me:(:(. In Shelly Cashman Series Microsoft Office 2000 there is a presentation concerning indexes. As with so many books in this field it is long on verbage and short on clarity. For example, on page A3.57 'In The Lab' #3, the directions are to display the Rental Unit table and order the records by bathrooms within bedrooms. With the index established and the asscending button executed for the bathrooms both columns change with bathrooms ordered assending in number of. The bedroom column does not achieve this same status. When the bedroom column is ordered the correct assending order is achieved by both columns. Question? What do they mean by "bathrooms within bedrooms?"

Thank you anybody.
cssii2000
 
Hi,
I think it is basically talking about secondary sort. I.e. when the bathroom column is ordered any results that have the same number of bathrooms are then sorted secondarily by some other column, but not bedrooms.
When the bedrooms were sorted in order those for which the numbers were tied were then sorted in order of the number of bathrooms.
Therefore the sort order is bedrooms then bathrooms or "bathrooms within bedrooms" as the bathrooms are sorted within each band of bedrooms.
e.g.
bedrooms bathrooms
1 1
1 2
1 5
2 3
2 4
2 6
3 1
3 3
3 5
so within the category those with for example 1 bedroom the results are sorted by bathroom.
I hope this is clearer,
Richard
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top