Adding 6 months to a date column

Sarnie83

Registered User.
Local time
Today, 06:36
Joined
Oct 6, 2014
Messages
20
Hi

I'm pretty sure this is fairly simple but just cannot remember how to do it (haven't used access in around 18 months).

I have a table that I am starting and have a column called DateFrom that I would like to create an extra column that displays the date in 6 months from that date (not 180 days)

Can this be done as a column or does it have to be done on a query? And is it the DateAdd function?

Thanks in Advance :)
 
Yes DATEADD.
You can put it in query or a form textbox.

DateAdd("m",6,[DateFld])
 
You would do this in a query. Calculated values shouldn't go into a table. However...

What does 6 months from a date mean? Months aren't a standard unit that is easily divisible. Some have 28 days, some 30, some 31, heck, 1 in almost every 50 has 29 days.

You can do DateAdd with a month argument, but it may not yield the results you want. For example, what's 6 months after these dates:


8/30/2015
8/31/2015
2/28/2016
2/29/2016
3/1/2016
 
Thanks everyone - plog that was actually really useful to think about!
 

Users who are viewing this thread

Back
Top Bottom