Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 5
Default Sorting by numbers w/ words in the same cells

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 a
$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!
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 3,572
Default Sorting by numbers w/ words in the same cells

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.
--
HTH,

RD

---------------------------------------------------------------------------
Please keep all correspondence within the NewsGroup, so all may benefit !
---------------------------------------------------------------------------

"guyfromage" wrote in message
...
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 a
$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!


  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 35,218
Default Sorting by numbers w/ words in the same cells

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.

guyfromage wrote:

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 a
$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!


--

Dave Peterson
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
Finding most common occurence of values in cells containing letters and numbers sparklyballs Excel Worksheet Functions 2 August 18th 06 12:16 PM
summing cells with text and numbers val Excel Worksheet Functions 1 August 2nd 06 03:26 AM
Sorting - cells containing numbers, numbers and letters Gunny Excel Discussion (Misc queries) 5 July 16th 06 01:22 AM
checking that cells have a value before the workbook will close kcdonaldson Excel Worksheet Functions 8 December 5th 05 04:57 PM
Sorting a range of cells that get value from other cells Matt Caswell Excel Discussion (Misc queries) 3 July 13th 05 04:52 PM


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

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

About Us

"It's about Microsoft Excel"