Sorting problem

  • Thread starter Thread starter Mark Christensen
  • Start date Start date
M

Mark Christensen

Hello,

I've got Excel 2002 SP3. I've got a spreadsheet with part numbers in column
A, and then prices in column B. I used Data > Sort by column A to get the
list of 600+ part numbers in alphanumeric order. The first five part
numbers are:

0405
0433
0435
0503
0615

This is fine. But then I have to scroll down about 30 rows to find these
part numbers:

0401-B
0406*
0422*
0423*

I would like these to be at the top of the list with the other part numbers
(so that 0401-B is first and the others fall in line where they should). Is
there a way to automatically do this? I don't want to have to manually move
rows because this sheet gets changed frequently and having to do anything
other than Data > Sort is really not feasible. Thanks.

Mark
 
If your part numbers are always 4 characters with possibly some others
as in your sample, you could introduce a new column with the formula

= LEFT(A2,4)

copied down the column for as many rows as you have. You could then
sort on this column first and column A second.

Pete
 
Pete,

Part numbers are not always 4 characters. I have:

28146
A28136
A110-11
C1470012

just as examples. Would your solution work with this?
 
No, the "28146" would be sorted as if it was 2814, though the codes
beginning with letters would be in the right place.

Pete
 
Back
Top