Dates in next week

  • Thread starter Thread starter 62microbus
  • Start date Start date
6

62microbus

Hi

im trying to do a query on a table of customers to find who has
birthday in the next week, the date of thire bithday is kept in th
format DD/MM so how can i compare it to the current date to get people
birthdays in the next week. does the date() function have the abilit
to just return the day and month?

thank
 
62,

Here's the best I can think of at the moment:
Make a new calculated field in the Field row of a blank column in the
query design grid, like this...
AdjustedBirthday: Right([Birthday],2) & Left([Birthday],2)
Then make another calculated field in the next blank column, like this...
TodayTest: Format(Date(),"mmdd")
In the first criteria row of the AdjustedBirthday column put...
Between Format(Date(),"mmdd") And Format(Date()+7,"mmdd")
.... and in this same criteria row of the TodayTest column, put...
<"1225"
Then, in the second criteria row of the AdjustedBirthday column put...
=Format(Date(),"mmdd") Or <=Format(Date()+7,"mmdd")
.... and in this same criteria row of the TodayTest colun, put...
 
Back
Top