#1   Report Post  
Posted to microsoft.public.excel.misc
RS RS is offline
external usenet poster
 
Posts: 113
Default Problem with Sorting

I am trying to sort the following, but keep getting the wrong answer. I want
A09-2 and A09-3 to be after A09-1, not the way it is shown below. I
appreciate any input. I know if I add a 0 in front of the 1, 2, or 3, it
will sort okay. However, I prefer to not have to do that. Any help would be
much appreciated!

A09-1
A09-10
A09-11
A09-12
A09-13
A09-14
A09-15
A09-16
A09-17
A09-18
A09-19
A09-2
A09-20
A09-21
A09-22
A09-23
A09-24
A09-25
A09-26
A09-27
A09-28
A09-29
A09-3

  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 2,389
Default Problem with Sorting

I don't know of any way. I would insert a helper column with the formula:
=if(len(a1)=5,left(a1,4)&"0"&right(a1,1),a1)

Then sort on that column. You can hide the column if you don't want it
displayed.

Regards,
Fred

"RS" wrote in message
...
I am trying to sort the following, but keep getting the wrong answer. I
want
A09-2 and A09-3 to be after A09-1, not the way it is shown below. I
appreciate any input. I know if I add a 0 in front of the 1, 2, or 3, it
will sort okay. However, I prefer to not have to do that. Any help would
be
much appreciated!

A09-1
A09-10
A09-11
A09-12
A09-13
A09-14
A09-15
A09-16
A09-17
A09-18
A09-19
A09-2
A09-20
A09-21
A09-22
A09-23
A09-24
A09-25
A09-26
A09-27
A09-28
A09-29
A09-3


  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 3,942
Default Problem with Sorting

hi,
in a column to the right of your data, enter this.....
=MID(A1,5,99)
copy the formula down then sort using the helper column as the primary key.
after the sort, you can delete the helper column.(or keep it for future
sorts if needed.)
Regards
FSt1

"RS" wrote:

I am trying to sort the following, but keep getting the wrong answer. I want
A09-2 and A09-3 to be after A09-1, not the way it is shown below. I
appreciate any input. I know if I add a 0 in front of the 1, 2, or 3, it
will sort okay. However, I prefer to not have to do that. Any help would be
much appreciated!

A09-1
A09-10
A09-11
A09-12
A09-13
A09-14
A09-15
A09-16
A09-17
A09-18
A09-19
A09-2
A09-20
A09-21
A09-22
A09-23
A09-24
A09-25
A09-26
A09-27
A09-28
A09-29
A09-3

  #4   Report Post  
Posted to microsoft.public.excel.misc
RS RS is offline
external usenet poster
 
Posts: 113
Default Problem with Sorting

It worked perfect! Thank you SO much for your assistance with this! RS

"FSt1" wrote:

hi,
in a column to the right of your data, enter this.....
=MID(A1,5,99)
copy the formula down then sort using the helper column as the primary key.
after the sort, you can delete the helper column.(or keep it for future
sorts if needed.)
Regards
FSt1

"RS" wrote:

I am trying to sort the following, but keep getting the wrong answer. I want
A09-2 and A09-3 to be after A09-1, not the way it is shown below. I
appreciate any input. I know if I add a 0 in front of the 1, 2, or 3, it
will sort okay. However, I prefer to not have to do that. Any help would be
much appreciated!

A09-1
A09-10
A09-11
A09-12
A09-13
A09-14
A09-15
A09-16
A09-17
A09-18
A09-19
A09-2
A09-20
A09-21
A09-22
A09-23
A09-24
A09-25
A09-26
A09-27
A09-28
A09-29
A09-3

  #5   Report Post  
Posted to microsoft.public.excel.misc
RS RS is offline
external usenet poster
 
Posts: 113
Default Problem with Sorting

This one worked perfect as well! Thank you SO much for your assistance, as
well! Now I have two formulas to use instead of none. Thank you! RS

"Fred Smith" wrote:

I don't know of any way. I would insert a helper column with the formula:
=if(len(a1)=5,left(a1,4)&"0"&right(a1,1),a1)

Then sort on that column. You can hide the column if you don't want it
displayed.

Regards,
Fred

"RS" wrote in message
...
I am trying to sort the following, but keep getting the wrong answer. I
want
A09-2 and A09-3 to be after A09-1, not the way it is shown below. I
appreciate any input. I know if I add a 0 in front of the 1, 2, or 3, it
will sort okay. However, I prefer to not have to do that. Any help would
be
much appreciated!

A09-1
A09-10
A09-11
A09-12
A09-13
A09-14
A09-15
A09-16
A09-17
A09-18
A09-19
A09-2
A09-20
A09-21
A09-22
A09-23
A09-24
A09-25
A09-26
A09-27
A09-28
A09-29
A09-3


.



  #6   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 2,389
Default Problem with Sorting

You're welcome. Thanks for the feedback.

Regards,
Fred

"RS" wrote in message
...
This one worked perfect as well! Thank you SO much for your assistance,
as
well! Now I have two formulas to use instead of none. Thank you! RS

"Fred Smith" wrote:

I don't know of any way. I would insert a helper column with the formula:
=if(len(a1)=5,left(a1,4)&"0"&right(a1,1),a1)

Then sort on that column. You can hide the column if you don't want it
displayed.

Regards,
Fred

"RS" wrote in message
...
I am trying to sort the following, but keep getting the wrong answer. I
want
A09-2 and A09-3 to be after A09-1, not the way it is shown below. I
appreciate any input. I know if I add a 0 in front of the 1, 2, or 3,
it
will sort okay. However, I prefer to not have to do that. Any help
would
be
much appreciated!

A09-1
A09-10
A09-11
A09-12
A09-13
A09-14
A09-15
A09-16
A09-17
A09-18
A09-19
A09-2
A09-20
A09-21
A09-22
A09-23
A09-24
A09-25
A09-26
A09-27
A09-28
A09-29
A09-3


.


Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
sorting problem 10 comes before 8 ty Excel Worksheet Functions 2 June 16th 09 06:51 PM
sorting problem Jack Sons Excel Discussion (Misc queries) 3 June 19th 08 11:07 PM
Sorting problem Craig[_3_] Excel Discussion (Misc queries) 5 January 26th 08 07:14 AM
SORTING PROBLEM Grace Excel Worksheet Functions 2 September 27th 06 08:10 PM
Sorting problem Klaus Excel Discussion (Misc queries) 3 December 4th 04 01:55 AM


All times are GMT +1. The time now is 04:40 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"