Comparing dates

  • Thread starter Thread starter Jeff
  • Start date Start date
J

Jeff

I'm trying to compare the DOB field in my child table to the report
start and report stop dates in my reporting dates table. Even though
all 3 fields are formatted as short-dates, using >= does not seem to
work. Is there another comparison function I need to use in order to
fix this issue?

Thanks

Jeff
 
Jeff said:
I'm trying to compare the DOB field in my child table to the report
start and report stop dates in my reporting dates table. Even though
all 3 fields are formatted as short-dates, using >= does not seem to
work. Is there another comparison function I need to use in order to
fix this issue?

Thanks

Jeff

Hi Jeff,

Formatting does not change the data, only the way it is displayed. If
the DOB has, say, 1962 as the year, that is the year part you are comparing.

If you are looking for upcoming birthdays you can use conversion
functions like DateSerial(), Year(), Month(), and Date() to compare the
month & date of the DOB in the current year. There is lots of material
posted on this.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top