Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
Alternating sort question
My wife is working on a spreadsheet for a class roster and one column
specifies gender (M,F). She would like to sort the students by alternating M & F instead of all M and then all F to assign a seating chart. Is this possible? Thanks in advance! GaryM |
#2
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
Alternating sort question
Perhaps you could sort by gender first to get all the F's together
then all the M's. Then fill a sequence down a helper column 1, 2, 3 etc for just the females. Fill a new sequence 1, 2, 3 etc down the column for just the males. Then you can sort the data plus the helper column using the helper sequence as the sort key (plus gender as the second key), and then you will get the sequence 1_F, 1_M, 2_F, 2_M, 3_F, 3_M etc. You can delete the helper column then. Obviously, if you have more of one gender then these will all appear together at the end. Hope this helps. Pete On Apr 27, 8:17*pm, GaryM wrote: My wife is working on a spreadsheet for a class roster and one column specifies gender (M,F). *She would like to sort the students by alternating M & F instead of all M and then all F to assign a seating chart. *Is this possible? *Thanks in advance! GaryM |
#3
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
Alternating sort question
Sort the students by gender. In an adjoining column, consecutively number the male students... say 1 thru 20 and then assign the same numbers to the female students... 1 thru 20. Select all the data including the new column and sort using the new column as the key. -- Jim Cone Portland, Oregon USA http://www.realezsites.com/bus/primitivesoftware (Excel Add-ins / Excel Programming) "GaryM" wrote in message My wife is working on a spreadsheet for a class roster and one column specifies gender (M,F). She would like to sort the students by alternating M & F instead of all M and then all F to assign a seating chart. Is this possible? Thanks in advance! GaryM |
#4
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
Alternating sort question
Probably an easier way but here goes my contribution.
DataFilterAutofilter for F on the gender column. In a helper column enter 1 through whatever using consecutive odd numbers. Show All then Filter on M and enter 2 through whatever using even numbers. Remove the Filter and sort by helper column. Gord Dibben MS Excel MVP On Sun, 27 Apr 2008 12:17:01 -0700, GaryM wrote: My wife is working on a spreadsheet for a class roster and one column specifies gender (M,F). She would like to sort the students by alternating M & F instead of all M and then all F to assign a seating chart. Is this possible? Thanks in advance! GaryM |
#5
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
Alternating sort question
I knew there was an easier way<g
Assign same numbers after filtering, not odds and evens. Gord On Sun, 27 Apr 2008 12:41:17 -0700, "Jim Cone" wrote: In an adjoining column, consecutively number the male students... say 1 thru 20 and then assign the same numbers to the female students... 1 thru 20. |
#6
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
Alternating sort question
The most difficult solution is usually the first one to come to mind. That's the way it works for me. <g Jim Cone "Gord Dibben" wrote in message I knew there was an easier way<g Assign same numbers after filtering, not odds and evens. Gord On Sun, 27 Apr 2008 12:41:17, "Jim Cone" wrote: In an adjoining column, consecutively number the male students... say 1 thru 20 and then assign the same numbers to the female students... 1 thru 20. |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
A question (sort of) | Excel Discussion (Misc queries) | |||
question on VB-sort | Excel Discussion (Misc queries) | |||
Sort question?? | Excel Discussion (Misc queries) | |||
sort question | Excel Worksheet Functions | |||
sort question | Excel Discussion (Misc queries) |