Subtracting months from a date

bruty

Active Member
Joined
Jul 25, 2007
Messages
451
If I have a date in Cell A1, what formula do I need to put in cell B1 to subtract 6 months.

eg If A1 = 14/08/2007 I want B1 to read 14/02/2007 and not 12/02/2007 which it reads when subtracting half a ywears worth of days
 

Excel Facts

Create a Pivot Table on a Map
If your data has zip codes, postal codes, or city names, select the data and use Insert, 3D Map. (Found to right of chart icons).

Aladin Akyurek

MrExcel MVP
Joined
Feb 14, 2002
Messages
85,210
If I have a date in Cell A1, what formula do I need to put in cell B1 to subtract 6 months.

eg If A1 = 14/08/2007 I want B1 to read 14/02/2007 and not 12/02/2007 which it reads when subtracting half a ywears worth of days

With the Analysis Toolpak active...

=EDATE(A1,-6)
 
Upvote 0

bruty

Active Member
Joined
Jul 25, 2007
Messages
451
ADVERTISEMENT
Cheers all for the quick replies
 
Upvote 0

Lewiy

Well-known Member
Joined
Jan 5, 2007
Messages
4,284
Yeah you’re right, scrap that. Jonmo’s is the best method I think.
 
Upvote 0

bruty

Active Member
Joined
Jul 25, 2007
Messages
451
If I have a date in Cell A1, what formula do I need to put in cell B1 to subtract 6 months.

eg If A1 = 14/08/2007 I want B1 to read 14/02/2007 and not 12/02/2007 which it reads when subtracting half a ywears worth of days

With the Analysis Toolpak active...

=EDATE(A1,-6)

Also works great, ta.
 
Upvote 0

Jonmo1

MrExcel MVP
Joined
Oct 12, 2006
Messages
44,061
while I don't think any method is truely perfect when dealing with dates. With my metod
Code:
=DATE(YEAR(A1),MONTH(A1)-6,DAY(A1))

This will fail on the 31st of just about any month, and especially in august, when 6 months prior is February...

Given
8/31/2007

There is no such date 2/31/2007..
closest date is 2/28/2007 - 3 days difference, so formula results in
3/3/2007


edit -

I'll take that back, the Edate does work nicely.
 
Upvote 0

Forum statistics

Threads
1,196,017
Messages
6,012,872
Members
441,737
Latest member
bijayche

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
Top