query: date selection style now()+5years

  • Thread starter geert.van.ransbeeck
  • Start date
G

geert.van.ransbeeck

Hi
I have a query with date field.
I want to select that date = today but in 5 years; so if we are
14/05/2009 today, I want all dates = 14/05/2014.

thanks a lot
g
 
J

John Spencer MVP

Use the dateAdd function to get the date in five years

DateAdd("yyyy",5,Date()) should return the date 5 years from today.

In the criteria under your field, enter the above expression.

John Spencer
Access MVP 2002-2005, 2007-2009
The Hilltop Institute
University of Maryland Baltimore County
 
Top