Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 4
Default Excel Data Sort - doesn't. HELP please

I have problem with a small database - it will not sort.
That is, it DOES change the data around, but not in any comprehensible way.
Having selected the database block, I requested "sort" on last column,
expecting to see a descending numeric order. I got garbage.
I cannot determine exactly what the order is, but it's certainly neither
numeric nor alpha. At least the "garbage" will "Undo" (reverts to original)
Nor is it related to the underlying reference cells which yield the number
Data Sort option is (correctly) set to sort "top to bottom" in descending
order - expected result, the data re-presented with last column in decending
order from 18 to 0.
..
Construction - 11 columns x 39 rows. No blank columns, rows or cells..
1st 2 columns are text (names), the remaining 9 are all numbers ranging from
0 to 18.
There are NO column headers. All the numeric cells are identically sized.
There are no merged cells.
All the numbers are calculated or derived from elsewhere in the spreadsheet,
i.e all function results or additions of disparate cells. All are valid - no
hashes/errors.

I've tested "sort" on a straightforward set of number columns - it works
fine, on single "direct-keyed" nuimbers !

HELP please.

Len


  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 22,906
Default Excel Data Sort - doesn't. HELP please

Len

The usual problem with bad sorting of numerical data is that some of the data
is Numerical and some is Text. The two sort differently.

What looks like a Number may be Text.

Try copying an empty cell then select your range of "numbers" and Paste
SpecialAddOKEsc.

This operation should change all "text numbers" to real numbers.

Try your sort again.

Gord Dibben XL2002

On Sun, 26 Oct 2003 00:32:10 +0100, "Len Dolby"
wrote:

I have problem with a small database - it will not sort.
That is, it DOES change the data around, but not in any comprehensible way.
Having selected the database block, I requested "sort" on last column,
expecting to see a descending numeric order. I got garbage.
I cannot determine exactly what the order is, but it's certainly neither
numeric nor alpha. At least the "garbage" will "Undo" (reverts to original)
Nor is it related to the underlying reference cells which yield the number
Data Sort option is (correctly) set to sort "top to bottom" in descending
order - expected result, the data re-presented with last column in decending
order from 18 to 0.
.
Construction - 11 columns x 39 rows. No blank columns, rows or cells..
1st 2 columns are text (names), the remaining 9 are all numbers ranging from
0 to 18.
There are NO column headers. All the numeric cells are identically sized.
There are no merged cells.
All the numbers are calculated or derived from elsewhere in the spreadsheet,
i.e all function results or additions of disparate cells. All are valid - no
hashes/errors.

I've tested "sort" on a straightforward set of number columns - it works
fine, on single "direct-keyed" nuimbers !

HELP please.

Len


  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 4
Default Excel Data Sort - doesn't. HELP please

Yes, it works - thanks ! But what a pain to have to redo the database ...

Whilst the spreadsheet itself includes individual data cells with "alpha"
text numbers, these are subsequently counted numerically - or so I thought.
It is these apparently numeric "count" cells which are transferred to the
database, not the original datacell(s)

=SUMPRODUCT(ISTEXT(E5:Y5)*(E5:Y5="1")) is a function used in cell AB5. (The
visible answer is 2). It is counting the instances of " '1") in data range
E5:Y5.
The answer 2 is transported to the database cell via "=$AB5+a series of
similar "count" cells in col $AB with same SUMPRODUCT function - the
database cell shows 10, the product of the "=$AB5+series..

Am copying to Tom (who supplied the function) as he may shed some light on
why what is apparently a numeric count is in fact text.
TOM - any idea why this count in SUMPRODUCT apparently yields a text number
? Better yet, how to systematically (programatically) restore the count to
numeric ?

Sincerely, Len




<Gord Dibben wrote in message
...
Len

The usual problem with bad sorting of numerical data is that some of the

data
is Numerical and some is Text. The two sort differently.

What looks like a Number may be Text.

Try copying an empty cell then select your range of "numbers" and Paste
SpecialAddOKEsc.

This operation should change all "text numbers" to real numbers.

Try your sort again.

Gord Dibben XL2002

On Sun, 26 Oct 2003 00:32:10 +0100, "Len Dolby"


wrote:

I have problem with a small database - it will not sort.
That is, it DOES change the data around, but not in any comprehensible

way.
Having selected the database block, I requested "sort" on last column,
expecting to see a descending numeric order. I got garbage.
I cannot determine exactly what the order is, but it's certainly neither
numeric nor alpha. At least the "garbage" will "Undo" (reverts to

original)
Nor is it related to the underlying reference cells which yield the

number
Data Sort option is (correctly) set to sort "top to bottom" in descending
order - expected result, the data re-presented with last column in

decending
order from 18 to 0.
.
Construction - 11 columns x 39 rows. No blank columns, rows or cells..
1st 2 columns are text (names), the remaining 9 are all numbers ranging

from
0 to 18.
There are NO column headers. All the numeric cells are identically sized.
There are no merged cells.
All the numbers are calculated or derived from elsewhere in the

spreadsheet,
i.e all function results or additions of disparate cells. All are valid -

no
hashes/errors.

I've tested "sort" on a straightforward set of number columns - it works
fine, on single "direct-keyed" nuimbers !

HELP please.

Len




  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 27,285
Default Excel Data Sort - doesn't. HELP please

The formula won't produce a text number.

More confusing is that you say Gordon's suggestion fixes it? His suggestion
will work with constants, but I wouldn't expect a similar effect with
formulas. You can check those cells with the same IsText or IsNumber
formula. Even if I formatted the cells as text, they were producing numeric
data.

I think the formulas you are trying to sort need to have absolute references
(your sample was relative for row)

=$AB$5+$AB$6

for example.

--
Regards,
Tom Ogilvy




Len Dolby wrote in message
...
Yes, it works - thanks ! But what a pain to have to redo the database ...

Whilst the spreadsheet itself includes individual data cells with "alpha"
text numbers, these are subsequently counted numerically - or so I

thought.
It is these apparently numeric "count" cells which are transferred to the
database, not the original datacell(s)

=SUMPRODUCT(ISTEXT(E5:Y5)*(E5:Y5="1")) is a function used in cell AB5.

(The
visible answer is 2). It is counting the instances of " '1") in data range
E5:Y5.
The answer 2 is transported to the database cell via "=$AB5+a series of
similar "count" cells in col $AB with same SUMPRODUCT function - the
database cell shows 10, the product of the "=$AB5+series..

Am copying to Tom (who supplied the function) as he may shed some light on
why what is apparently a numeric count is in fact text.
TOM - any idea why this count in SUMPRODUCT apparently yields a text

number
? Better yet, how to systematically (programatically) restore the count to
numeric ?

Sincerely, Len




<Gord Dibben wrote in message
...
Len

The usual problem with bad sorting of numerical data is that some of the

data
is Numerical and some is Text. The two sort differently.

What looks like a Number may be Text.

Try copying an empty cell then select your range of "numbers" and Paste
SpecialAddOKEsc.

This operation should change all "text numbers" to real numbers.

Try your sort again.

Gord Dibben XL2002

On Sun, 26 Oct 2003 00:32:10 +0100, "Len Dolby"


wrote:

I have problem with a small database - it will not sort.
That is, it DOES change the data around, but not in any comprehensible

way.
Having selected the database block, I requested "sort" on last column,
expecting to see a descending numeric order. I got garbage.
I cannot determine exactly what the order is, but it's certainly

neither
numeric nor alpha. At least the "garbage" will "Undo" (reverts to

original)
Nor is it related to the underlying reference cells which yield the

number
Data Sort option is (correctly) set to sort "top to bottom" in

descending
order - expected result, the data re-presented with last column in

decending
order from 18 to 0.
.
Construction - 11 columns x 39 rows. No blank columns, rows or cells..
1st 2 columns are text (names), the remaining 9 are all numbers ranging

from
0 to 18.
There are NO column headers. All the numeric cells are identically

sized.
There are no merged cells.
All the numbers are calculated or derived from elsewhere in the

spreadsheet,
i.e all function results or additions of disparate cells. All are

valid -
no
hashes/errors.

I've tested "sort" on a straightforward set of number columns - it

works
fine, on single "direct-keyed" nuimbers !

HELP please.

Len






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
Excel - data autofilter, then data sort how do you view all Peg Excel Discussion (Misc queries) 2 April 23rd 08 11:11 PM
Excel data sort Stacyb Excel Worksheet Functions 1 January 7th 08 03:37 PM
data, sort option is grayed. how to sort on a column? Steve Richter Excel Discussion (Misc queries) 1 September 25th 07 03:25 PM
I want to convert word column data to excel row data to sort addre craywill Excel Discussion (Misc queries) 0 April 18th 06 07:16 PM
How do I sort a column of data and have each data row sort accordi Oedalis Excel Discussion (Misc queries) 1 March 17th 05 11:52 PM


All times are GMT +1. The time now is 01:16 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"