Extract Birthday Month and Day (1 Viewer)

OldManLearning

New member
Local time
Today, 07:11
Joined
Jul 6, 2022
Messages
3
I am working on a database for our class of about 150 members. ID, name, birthday (Date field), etc. Many people don't want to publish their age so many of the records only have "Month" and "Day". I have been using year(Date() to provide the missing year. I am using DatePart("m",[tblFamily].[BirthDate]) to filter by month. I can also further tilter the query by using DatePart('d', Birthday

The problem I am having is when the dates span different months, such as June 26th to July 2nd. I have tried "DateSerial" , but I can't seem to filter the data

I would really appreciate any help.

Thanks,
John
 

arnelgp

..forever waiting... waiting for jellybean!
Local time
Today, 19:11
Joined
May 7, 2009
Messages
19,230
you add an Expression to your Query:

Expr1: Format([BirthDate], "mmdd")

Now you can filter this Expr1 using

>= "0626" And <= "0702"

(greater or equal to june 26 and less or equal to july 2)
 

OldManLearning

New member
Local time
Today, 07:11
Joined
Jul 6, 2022
Messages
3
you add an Expression to your Query:

Expr1: Format([BirthDate], "mmdd")

Now you can filter this Expr1 using

>= "0626" And <= "0702"

(greater or equal to june 26 and less or equal to july 2)
Thank you very much. It is really easy when you know what you are doing!
 

Users who are viewing this thread

Top Bottom