A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Excel » General Discussion
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

Sorting data with the letter 'E' included



 
 
Thread Tools Display Modes
  #1  
Old November 17th, 2009, 01:40 PM posted to microsoft.public.excel.misc
LyleB_Austin
external usenet poster
 
Posts: 5
Default Sorting data with the letter 'E' included

I have a list of department codes that I need to sort. They are in the
format number, letter, number, number. All end in zero; for example 2C00,
5D00, 2E10. In most cases the last two numbers are zeros. The problem is
with the codes that contain the letter 'E'. I was originally having the
problem of Excel seeing all codes containing the letter 'E' as numbers and
putting them into scientific notation. I subsequently formatted them as text
which fixed the display problem, but now when I sort, all the department
codes that contain 'E' are sorting at the top. For example instead of
getting something like 1A00, 1B00, 1C00, etc., I'm getting 1E00, 1A00, 1B00,
etc. I've tried formatting as both 'text' and 'general', but no luck.

I'm using Excel 2007, but saving file as 2003 since not everyone where I
work has been migrated to 2007.
  #2  
Old November 17th, 2009, 01:52 PM posted to microsoft.public.excel.misc
Bob I
external usenet poster
 
Posts: 10,698
Default Sorting data with the letter 'E' included

Set format as text first, then place the data in the cells.

LyleB_Austin wrote:
I have a list of department codes that I need to sort. They are in the
format number, letter, number, number. All end in zero; for example 2C00,
5D00, 2E10. In most cases the last two numbers are zeros. The problem is
with the codes that contain the letter 'E'. I was originally having the
problem of Excel seeing all codes containing the letter 'E' as numbers and
putting them into scientific notation. I subsequently formatted them as text
which fixed the display problem, but now when I sort, all the department
codes that contain 'E' are sorting at the top. For example instead of
getting something like 1A00, 1B00, 1C00, etc., I'm getting 1E00, 1A00, 1B00,
etc. I've tried formatting as both 'text' and 'general', but no luck.

I'm using Excel 2007, but saving file as 2003 since not everyone where I
work has been migrated to 2007.


  #4  
Old November 17th, 2009, 02:00 PM posted to microsoft.public.excel.misc
Luke M
external usenet poster
 
Posts: 2,672
Default Sorting data with the letter 'E' included

Even with the cell formatting, XL is trying to be *helpful* and sort what it
believes is a number as a number. We can "cheat" with a helper column. Insert
a column, and use this formula, copied down:
=LEFT(A2,4)&"Z"

Now XL is forced to treat our values as text. Sort on this helper column,
and you should get your desired results.
--
Best Regards,

Luke M
*Remember to click "yes" if this post helped you!*


"LyleB_Austin" wrote:

I have a list of department codes that I need to sort. They are in the
format number, letter, number, number. All end in zero; for example 2C00,
5D00, 2E10. In most cases the last two numbers are zeros. The problem is
with the codes that contain the letter 'E'. I was originally having the
problem of Excel seeing all codes containing the letter 'E' as numbers and
putting them into scientific notation. I subsequently formatted them as text
which fixed the display problem, but now when I sort, all the department
codes that contain 'E' are sorting at the top. For example instead of
getting something like 1A00, 1B00, 1C00, etc., I'm getting 1E00, 1A00, 1B00,
etc. I've tried formatting as both 'text' and 'general', but no luck.

I'm using Excel 2007, but saving file as 2003 since not everyone where I
work has been migrated to 2007.

 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump


All times are GMT +1. The time now is 08:54 PM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 OfficeFrustration.
The comments are property of their posters.