Separating Month and Year from a Date

baltjazz08

New Member
Joined
May 3, 2011
Messages
9
Good afternoon -

I have two date fields in a result set that are currently in the 'mm/dd/yyyy' format that I am trying to convert (not format) to a 'Month-Year' format. So '05/22/2009' should be converted to 'May-2009'. Simply formatting the columns in the available 'M-01' format does nothing, since the underlying date remains. I have other categorization columns that I am trying to group according to month and year, but the day in the date prevents them from grouping properly. Any ideas how to do this?

Thanks,
TJ
 

Excel Facts

How to change case of text in Excel?
Use =UPPER() for upper case, =LOWER() for lower case, and =PROPER() for proper case. PROPER won't capitalize second c in Mccartney
Welcome to the board...

You'll have to convert them all to the 1st day of the month.
A real date MUST contain a DAY, otherwise it's not a date...

But if you make them ALL the 1st, then you can establish some control with Month and Year...

=A1-DAY(A1)+1

That will convert ANY Date to the 1st of it's respective month/year.


Hope that helps.
 
Upvote 0

Forum statistics

Threads
1,224,586
Messages
6,179,729
Members
452,939
Latest member
WCrawford

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top