Want to protect your cyber security and still get fast solutions? Ask a secure question today.Go Premium

x
Solved

# Extract dy month and year from date in excel 2007

Posted on 2011-10-04
Medium Priority
277 Views
Hi There,

I have a huge amount of data coming in.
One of the fields is in the format
Fri Apr 06 01:04:46 2011

I need to extract this in three separte columns as

Month      Day     year
Apr           06       2011

I tried the month and year does not work.

Any help would be appreciated.

0
• 2
• 2

LVL 33

Accepted Solution

jppinto earned 2000 total points
ID: 36911815
If the data is formated as text, not date, then you can use some simple MID and RIGHT functions like on the attached file.
If the data is formated as date, you could do it simple using MONTH, DAY and YEAR functions.

jppinto
Extract-Dates.xlsx
0

LVL 50

Expert Comment

ID: 36911822
Try these formulas for Month, Day and Year respectively, assuming data in A2

=RIGHT(A2,4)

=MID(A2,5,3)

=MID(A2,9,2)

regards, barry
0

LVL 33

Expert Comment

ID: 36911890
Barry, this where my proposed formulas:

=RIGHT(A2,4)
=MID(A2,5,3)
=MID(A2,9,2)

You were right on target! LOLOL

Regards,

jppinto
0

LVL 50

Expert Comment

ID: 36912429
....great minds, JP.....

My only reservation about those formulas is that the results are text, maybe better to convert to a date then you can do any "date math" you want......

regards, barry
0

## Featured Post

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This code takes an Excel list of URL’s and adds a header titled “URL List”. It then searches through all URL’s in column “A”, looking for duplicates. When a duplicate is found, it is moved to the top of the list. The duplicate URL’s are then highlig…
This article describes how to use a set of graphical playing cards to create a Draw Poker game in Excel or VB6.
The viewer will learn how to create two correlated normally distributed random variables in Excel, use a normal distribution to simulate the return on different levels of investment in each of the two funds over a period of ten years, and, create a …
This Micro Tutorial will demonstrate on a Mac how to change the sort order for chart legend values and decrpyt the intimidating chart menu.
###### Suggested Courses
Course of the Month10 days, 23 hours left to enroll

#### 571 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.