Sorting by numbers w/ words in the same cells

G

guyfromage

I'm trying to sort a grid that ranks 5 rows from lowest to highest based on
the dollar amount in column D. Columns A-I all have different info in them.
In column D, the values going down are:
$6342 yrs 1-6; $4286 yrs 7+
$6346
$6641
$7519
$11426
I want to sort columns B-I (as they are ranked 1 thru 5 in column A) and use
the values in column D as the basis for it. But when I sort, it
automatically puts the cell w/ the extra verbiage in it ("yrs 1-6...") at the
bottom, even though the dollar amount is the lowest.
How can I sort by just the first full number?
Thanks!
 
R

RagDyer

You might try TTC (Text To Columns) to insert a 'helper' column, and then
use that temp column as the sort key.

Select Column D containing your values, then:
<Data> <Text To Columns> <Delimited> <Next>

Click on "Space", then <Next>

The first column in the preview window containing your numbers is selected
by default.
Click in the next column's header, hold <Shift>, and click in the last
column's header to select all of them.
While they're *still* selected, click on "Do Not Import Column".
The headers now change to "Skip".

Now, click in the "Destination" box, and change the default location to
J1
Which will direct the insertion of this temporary helper column to the end
of your datalist (you did say A to I - didn't you).
Then <Finish>.

You'll see that your original data is untouched, and *only* the numbers
column was appended to the end of your datalist.

Now, simply select the entire range which you wish to sort, *including
Column J*, and sort using J as the sort key.

After you're done, you can delete it.
 
D

Dave Peterson

As long as the first "words" are the numbers, you could use a helper column of
cells and sort by that.

I'd insert a new column E and use:

=--LEFT(E1,SEARCH(" ",E1&" "))

And drag down.

Then select the whole range and sort by that new column E.
 

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

Similar Threads


Top