sorting cells that contain spaces and hyphens

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Can anyone tell how I can sort a list where the cell contents contain spaces
and hyphens? For example I have a list of part numbers coming out in the
following order:
0200 .2285-001-0-00
0200 .5126-006-0-00
0200 .5305-001-0-00
0200 .3200-006-0-00
0200 .2850-006-0-00

I need the list to come out like:
0200 .2285-001-0-00
0200 .2850-006-0-00
0200 .3200-006-0-00
0200 .5126-006-0-00
0200 .5305-001-0-00

Any way to do this?
 
Can anyone tell how I can sort a list where the cell contents contain spaces
and hyphens? For example I have a list of part numbers coming out in the
following order:
0200 .2285-001-0-00
0200 .5126-006-0-00
0200 .5305-001-0-00
0200 .3200-006-0-00
0200 .2850-006-0-00

I need the list to come out like:
0200 .2285-001-0-00
0200 .2850-006-0-00
0200 .3200-006-0-00
0200 .5126-006-0-00
0200 .5305-001-0-00

Any way to do this?

in a helper column, use something like this and sort on that column.
=SUBSTITUTE(SUBSTITUTE(A2,"-","")," ","")
 
amaries said:
Can anyone tell how I can sort a list where the cell contents contain
spaces
and hyphens? For example I have a list of part numbers coming out in the
following order:
0200 .2285-001-0-00
0200 .5126-006-0-00
0200 .5305-001-0-00
0200 .3200-006-0-00
0200 .2850-006-0-00

I need the list to come out like:
0200 .2285-001-0-00
0200 .2850-006-0-00
0200 .3200-006-0-00
0200 .5126-006-0-00
0200 .5305-001-0-00

Any way to do this?

Unless I've misunderstood, the ordinary Excel sort function will do this by
default. Try it, and post back with details if it doesn't do what you want.

Stephen
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top