By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
435,481 Members | 3,046 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 435,481 IT Pros & Developers. It's quick & easy.

Between [Enter Start Date] And [Enter End Date] in QRY Problem

P: n/a
I have a query with a date field criteria of:
Between [Enter Start Date] And [Enter End Date]

When the query is run, I am asked for the Start date and then the End
Date. So far, so good.

The records returned are all those in between those dates and not
records that are on the start or the end date.

For example, I enter "09/01/03" for the start date and "09/30/03" for
the end date. I do not see records that are marked on the 1st or the
30th of September 2003. I only see records with dates in between.

The end user isn't going to think to enter "08/31/03" and "10/01/03"
to get all of September's records. They are just going to enter the
september dates.

Can anyone help me with this?

Thank you kindly,

Dave
Nov 12 '05 #1
Share this Question
Share on Google+
3 Replies


P: n/a

"David Kuhn" <dk***@acsworld.com> skrev i en meddelelse
news:45*************************@posting.google.co m...
I have a query with a date field criteria of:
Between [Enter Start Date] And [Enter End Date]

When the query is run, I am asked for the Start date and then the End
Date. So far, so good.

The records returned are all those in between those dates and not
records that are on the start or the end date.

For example, I enter "09/01/03" for the start date and "09/30/03" for
the end date. I do not see records that are marked on the 1st or the
30th of September 2003. I only see records with dates in between.

The end user isn't going to think to enter "08/31/03" and "10/01/03"
to get all of September's records. They are just going to enter the
september dates.

Can anyone help me with this?

Thank you kindly,

Dave
Just a quick one.
Can't you just type :=[Enter Start Date] And <=[Enter End Date]


Jan
Nov 12 '05 #2

P: n/a
"David Kuhn" <dk***@acsworld.com> wrote in message
news:45*************************@posting.google.co m...
I have a query with a date field criteria of:
Between [Enter Start Date] And [Enter End Date]

When the query is run, I am asked for the Start date and then the End
Date. So far, so good.

The records returned are all those in between those dates and not
records that are on the start or the end date.

For example, I enter "09/01/03" for the start date and "09/30/03" for
the end date. I do not see records that are marked on the 1st or the
30th of September 2003. I only see records with dates in between.

The end user isn't going to think to enter "08/31/03" and "10/01/03"
to get all of September's records. They are just going to enter the
september dates.


BETWEEN is inclusive, but if your records include time and you only supply a date as
the filter then you will only get records on the end date that fall exactly at
midnight. It should work as expected for the start date though (you might want to
check that again).

You either need to use DateValue() to strip the time off during the test or add a day
to the end date.

Between [Enter Start Date] And DateAdd("d", 1,[Enter End Date])

Nov 12 '05 #3

P: n/a
I liked the first answer but I am throwing this idea in for similar
problems.
If I am running a query of a form with an easily entered bit of data I
sometimes use an invisible field to manipulate the data to the form I
want in this way I can re-use the manipulated data in a number of
queries simply by referring to the invisible field(s)

*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!
Nov 12 '05 #4

This discussion thread is closed

Replies have been disabled for this discussion.