View Single Post
  #5 (permalink)  
Old December 12th, 2005, 06:00 PM
kindler kindler is offline
Friend of Wrox
Join Date: Dec 2005
Location: , , .
Posts: 142
Thanks: 0
Thanked 0 Times in 0 Posts

What you're attempting should probably be done using VB and DAO RecordSets to parse the sorted (descending) age table, and create a new table based on those results. You shouldn't need to add a new column to the original table, just some code like:

Set rst 'blah blah blah
If Not rst.BOF And Not rst.EOF
colName = rst.Name
colAge = rst.Age
rank = 1
Do Until rst.EOF
If colAge = rst.Age Then
'Add colName, Rank to new table
'Add colName, Rank to new table
Rank = Rank + 1
End If
'Add colName, Rank (not sure about this, figure out if necessary to avoid off-by-one error

Reply With Quote