Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 2
Default Convert numbers to date: "586" to read "May 1986"

I have a huge spreadsheet where all the dates in the date column are listed
as myy. For example "586" should be May 1986, and "801" should be August
2001.

Is there any way to convert the whole column so i dont' have to manually
change them?

If it helps, the file was an Access file my client burned toa CD. I opened
it on another computer and this was how the column appeared, so I'mnot sure
if its a formatting error on his end, or if that is how he actually entered
the data.

Thanks
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 1,104
Default Convert numbers to date: "586" to read "May 1986"

Let's say the dates are in column C and the first one is in C2.
Insert a new column D (we will get rid of it soon!)
In D2 enter
=DATE(IF(MOD(C2,100)<10,MOD(C2,100)+2000,MOD(C2,10 0)+1900),INT(C2/100),1)
Now format it with Custom Format of <mmmm yyyy or just <mmm yyyy for
three-letter month names
Copy this down the column - quickest way is to double click D2's fill handle
which is the small solid square in lower right corner of a active cell.
Select all of the D column and copy; with it still selected use Edit | Paste
Special :Values.
Now the D data is a real dates not a formulas so you can delete column C,
making the D column the C column with the dates you want.
best wishes
--
Bernard V Liengme
Microsoft Excel MVP
http://people.stfx.ca/bliengme
remove caps from email

"CEckels" wrote in message
...
I have a huge spreadsheet where all the dates in the date column are listed
as myy. For example "586" should be May 1986, and "801" should be August
2001.

Is there any way to convert the whole column so i dont' have to manually
change them?

If it helps, the file was an Access file my client burned toa CD. I
opened
it on another computer and this was how the column appeared, so I'mnot
sure
if its a formatting error on his end, or if that is how he actually
entered
the data.

Thanks



  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 2,059
Default Convert numbers to date: "586" to read "May 1986"

"CEckels" wrote:
I'mnot sure if its a formatting error on his end, or if that is how he
actually entered the data.


Of course, you should determine that first. Select a cell, right-click and
click Format Number. If you see a Custom format of the form "myy", select
the entire column of dates, right-click and click Format Number, then
select Custom format and enter "mmm yyyy" without the quotes.

Otherwise....


Is there any way to convert the whole column so i dont' have to manually
change them?


One way.... In a parallel column, enter the following formula and copy down
as needed:

=datevalue(left(A1,len(A1)-2) & "/1/" & right(A1,2))

assuming the first bogus date (e.g. 586) is in A1. Then select the new
column of dates and press ctrl-C to copy. Then select the original column
of dates, right-click and click Paste Special Value OK. You can now
delete the new column of dates.

PS: One way to select a large range of cells is to enter the range in the
Name Box in the upper left corner above the worksheet.


----- original message -----

"CEckels" wrote in message
...
I have a huge spreadsheet where all the dates in the date column are listed
as myy. For example "586" should be May 1986, and "801" should be August
2001.

Is there any way to convert the whole column so i dont' have to manually
change them?

If it helps, the file was an Access file my client burned toa CD. I
opened
it on another computer and this was how the column appeared, so I'mnot
sure
if its a formatting error on his end, or if that is how he actually
entered
the data.

Thanks


  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 2,059
Default Convert numbers to date: "586" to read "May 1986"

PS....

I wrote:
Then select the new column of dates and press ctrl-C to copy. Then select
the original
column of dates, right-click and click Paste Special Value OK.


I neglected to add: and format the column of dates with the Custom "mmm
yyyy" format.


----- original message -----

"JoeU2004" wrote in message
...
"CEckels" wrote:
I'mnot sure if its a formatting error on his end, or if that is how he
actually entered the data.


Of course, you should determine that first. Select a cell, right-click
and click Format Number. If you see a Custom format of the form "myy",
select the entire column of dates, right-click and click Format Number,
then select Custom format and enter "mmm yyyy" without the quotes.

Otherwise....


Is there any way to convert the whole column so i dont' have to manually
change them?


One way.... In a parallel column, enter the following formula and copy
down as needed:

=datevalue(left(A1,len(A1)-2) & "/1/" & right(A1,2))

assuming the first bogus date (e.g. 586) is in A1. Then select the new
column of dates and press ctrl-C to copy. Then select the original column
of dates, right-click and click Paste Special Value OK. You can now
delete the new column of dates.

PS: One way to select a large range of cells is to enter the range in the
Name Box in the upper left corner above the worksheet.


----- original message -----

"CEckels" wrote in message
...
I have a huge spreadsheet where all the dates in the date column are
listed
as myy. For example "586" should be May 1986, and "801" should be August
2001.

Is there any way to convert the whole column so i dont' have to manually
change them?

If it helps, the file was an Access file my client burned toa CD. I
opened
it on another computer and this was how the column appeared, so I'mnot
sure
if its a formatting error on his end, or if that is how he actually
entered
the data.

Thanks



  #5   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 3,718
Default Convert numbers to date: "586" to read "May 1986"

Try this:

=--REPLACE(A1,LEN(A1)-1,,"/1/")

Format cell as: mmmm yyyy


"CEckels" wrote:

I have a huge spreadsheet where all the dates in the date column are listed
as myy. For example "586" should be May 1986, and "801" should be August
2001.

Is there any way to convert the whole column so i dont' have to manually
change them?

If it helps, the file was an Access file my client burned toa CD. I opened
it on another computer and this was how the column appeared, so I'mnot sure
if its a formatting error on his end, or if that is how he actually entered
the data.

Thanks



  #6   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 2
Default Convert numbers to date: "586" to read "May 1986"

Many thanks to all who replied. All of your suggestions worked.

You've saved me hours!!

"CEckels" wrote:

I have a huge spreadsheet where all the dates in the date column are listed
as myy. For example "586" should be May 1986, and "801" should be August
2001.

Is there any way to convert the whole column so i dont' have to manually
change them?

If it helps, the file was an Access file my client burned toa CD. I opened
it on another computer and this was how the column appeared, so I'mnot sure
if its a formatting error on his end, or if that is how he actually entered
the data.

Thanks

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 - Golf - how to display "-2" as "2 Under" or "4"as "+4" or "4 Over" in a calculation cell Steve Kay Excel Discussion (Misc queries) 2 August 8th 08 01:54 AM
any formula to convert numbers in word form, e.g. "2" as "Two"? Neeraj Excel Worksheet Functions 1 May 26th 08 01:03 PM
change "true" and "false" to "availble" and "out of stock" inthestands Excel Worksheet Functions 2 July 19th 07 07:05 PM
HELP on "left","right","find","len","substitute" functions serene83 Excel Discussion (Misc queries) 5 June 27th 06 02:23 AM
Count occurences of "1"/"0" (or"TRUE"/"FALSE") in a row w. conditions in the next BCB New Users to Excel 7 May 13th 06 10:02 PM


All times are GMT +1. The time now is 02:56 PM.

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

About Us

"It's about Microsoft Excel"