begginer Q, date

J

John Spencer

Your question is unclear.

Do you want anyone that has a birthdate after today? Essentially, no one
has been born after today, so this would be entry errors
Field: BirthDate
Criteria: > Date()

Do you want anyone that has a birthday on or after today's date for the
remainder of the year?
Field: MonthAndDay: Format(BirthDate,"MMDD")
Criteria: >= Format(Date(),"MMDD")


--
John Spencer
Access MVP 2002-2005, 2007
Center for Health Program Development and Management
University of Maryland Baltimore County
..
 
J

John W. Vinson

How to filter query to list all date field who have birthday from NOW date?
Tnx

Assuming that you have the person's date of birth in a field named DOB (e.g.
#5/16/1946#), you can use a calculated field in a query: in a vacant field
cell type

Birthday: DateSerial(Year(Date()), Month([DOB]), Day([DOB]))

This field will contain the current year's birthday anniversary. You can use a
criterion

BETWEEN Date() AND Date() + 7

to see the upcoming week's birthdays. Note that this won't work in the last
week of the year; you can get fancier with the expression if that's a problem.

John W. Vinson [MVP]
 
D

Domagoj

tnx!
John W. Vinson said:
How to filter query to list all date field who have birthday from NOW date?
Tnx

Assuming that you have the person's date of birth in a field named DOB (e.g.
#5/16/1946#), you can use a calculated field in a query: in a vacant field
cell type

Birthday: DateSerial(Year(Date()), Month([DOB]), Day([DOB]))

This field will contain the current year's birthday anniversary. You can use a
criterion

BETWEEN Date() AND Date() + 7

to see the upcoming week's birthdays. Note that this won't work in the last
week of the year; you can get fancier with the expression if that's a problem.

John W. Vinson [MVP]
 
D

Domagoj

I cant use sorting or between after I do that!?

John W. Vinson said:
How to filter query to list all date field who have birthday from NOW date?
Tnx

Assuming that you have the person's date of birth in a field named DOB (e.g.
#5/16/1946#), you can use a calculated field in a query: in a vacant field
cell type

Birthday: DateSerial(Year(Date()), Month([DOB]), Day([DOB]))

This field will contain the current year's birthday anniversary. You can use a
criterion

BETWEEN Date() AND Date() + 7

to see the upcoming week's birthdays. Note that this won't work in the last
week of the year; you can get fancier with the expression if that's a problem.

John W. Vinson [MVP]
 
D

Douglas J. Steele

Why not?

--
Doug Steele, Microsoft Access MVP

(no private e-mails, please)


Domagoj said:
I cant use sorting or between after I do that!?

John W. Vinson said:
How to filter query to list all date field who have birthday from NOW date?
Tnx

Assuming that you have the person's date of birth in a field named DOB (e.g.
#5/16/1946#), you can use a calculated field in a query: in a vacant
field
cell type

Birthday: DateSerial(Year(Date()), Month([DOB]), Day([DOB]))

This field will contain the current year's birthday anniversary. You can use a
criterion

BETWEEN Date() AND Date() + 7

to see the upcoming week's birthdays. Note that this won't work in the last
week of the year; you can get fancier with the expression if that's a problem.

John W. Vinson [MVP]
 
Top