ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   Sort function problem (https://www.excelbanter.com/excel-worksheet-functions/155341-sort-function-problem.html)

SJC

Sort function problem
 
I have a spreadsheet which displays data in rows for about 350 different
clients. Each client has an assigned number which leads each row. When I
sort the rows so that they will appear in numerical order, the majority of
the rows are sorted correctly, but about 30 rows are brought to the top of
the spreadsheet out of order. Besides cutting and pasting them where they
belong, are there any other options for fixing this sorting problem?

George Nicholson

Sort function problem
 
Sounds like you have some client 'numbers' that are actually being stored as
Text. Using formatting to "convert" them is often a waste of time. What I
usually do is:
- Format an empty cell with the same format you want applied to your text
numbers
- Place the number 1 in that cell (important to apply number formatting
to cell first, to make sure it isn't text)
- Copy
- Select the text numbers you want to convert
- EditPasteSpecial. Select both "Values & Number Formats" and Multiply.
OK

HTH,


"SJC" wrote in message
...
I have a spreadsheet which displays data in rows for about 350 different
clients. Each client has an assigned number which leads each row. When I
sort the rows so that they will appear in numerical order, the majority of
the rows are sorted correctly, but about 30 rows are brought to the top of
the spreadsheet out of order. Besides cutting and pasting them where they
belong, are there any other options for fixing this sorting problem?




Michael

Sort function problem
 
Must likely those clients have a leading blank space, what you should do is
do a find and replace of the blank space before you do the sorting.
Or insert a column and place the trim function in it then do a copy paste
values on the source columns to eliminate non printable characters then
proceed to sort.

Example
A1 B1
123 =Trim(a1)




--
If this posting was helpful, please click on the Yes button.
Regards,

Michael Arch.




"SJC" wrote:

I have a spreadsheet which displays data in rows for about 350 different
clients. Each client has an assigned number which leads each row. When I
sort the rows so that they will appear in numerical order, the majority of
the rows are sorted correctly, but about 30 rows are brought to the top of
the spreadsheet out of order. Besides cutting and pasting them where they
belong, are there any other options for fixing this sorting problem?


SJC

Sort function problem
 
Thanks much. This suggestion fixed most of my problem, and the second
suggestion below yours took care of the rest of them. Much appreciated.

"Michael" wrote:

Must likely those clients have a leading blank space, what you should do is
do a find and replace of the blank space before you do the sorting.
Or insert a column and place the trim function in it then do a copy paste
values on the source columns to eliminate non printable characters then
proceed to sort.

Example
A1 B1
123 =Trim(a1)




--
If this posting was helpful, please click on the Yes button.
Regards,

Michael Arch.




"SJC" wrote:

I have a spreadsheet which displays data in rows for about 350 different
clients. Each client has an assigned number which leads each row. When I
sort the rows so that they will appear in numerical order, the majority of
the rows are sorted correctly, but about 30 rows are brought to the top of
the spreadsheet out of order. Besides cutting and pasting them where they
belong, are there any other options for fixing this sorting problem?


SJC

Sort function problem
 
Thanks very much--both of your suggestions make it work perfect--appreciate
the help!

"George Nicholson" wrote:

Sounds like you have some client 'numbers' that are actually being stored as
Text. Using formatting to "convert" them is often a waste of time. What I
usually do is:
- Format an empty cell with the same format you want applied to your text
numbers
- Place the number 1 in that cell (important to apply number formatting
to cell first, to make sure it isn't text)
- Copy
- Select the text numbers you want to convert
- EditPasteSpecial. Select both "Values & Number Formats" and Multiply.
OK

HTH,


"SJC" wrote in message
...
I have a spreadsheet which displays data in rows for about 350 different
clients. Each client has an assigned number which leads each row. When I
sort the rows so that they will appear in numerical order, the majority of
the rows are sorted correctly, but about 30 rows are brought to the top of
the spreadsheet out of order. Besides cutting and pasting them where they
belong, are there any other options for fixing this sorting problem?






All times are GMT +1. The time now is 01:48 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com