Way to only query Day and month?

masterkale

AuzSolutions
Local time
Tomorrow, 01:18
Joined
Sep 19, 2006
Messages
22
Hi,

I was wondering is there a way to only QUERY day and month?

dd/MM ?

The issue is i need to build a report that has all the accounts opened within a certain month/time period. BUT its not year specific so i would need for instance.

01/02 to 28/02
dd/mm dd/mm

Note: The date stored in the DB is in this format dd/mm/yy < Standard format.

Is there a way to do this?
Your help is much appreciated... THANK YOU..

Cheers
Tristan F
 
have columns in your query called month(mydate) and day(mydate), then test them as you require
 
Thanks.

Sorry for my ignorance, but how would you structure so you get a column that has, dd/mm like this > day(mydate)/month(mydate).

Would access handle that properly..?
Im just aunable to test now, will check when im home tongiht...

Cheers
Tristan F
 
The Day and Month function give answers that corresponds to that part of the date

You can make calculated fields in a query. On the query grid you enter something like this:

MyDayNumber:Day([MyDateField])

MyMonthNumber:Month([MyDateField])

So if on a record MyDateField is September 27 then you will get 27 and 9 in the two calculated fields you created
 
I think that the simplest way to do this is to take year out of the equation with Dateserial and then use Between.. And... in the criteria

eg in the query
testdate: Dateserial(Year(#01/01/1900#), Month(yourfield),day(yourfield))

Criteria Between #01/02/1900# and #28/02/1900#

Brian
 

Users who are viewing this thread

Back
Top Bottom