Query Problem: Between [Enter W/E Date] And ([Enter W/E Date]-6)

  • Thread starter Thread starter Daveo
  • Start date Start date
D

Daveo

Hi there,

I have a query in which I want to able to enter a week ending date, and
the query will then return results for that whole week. e.g. if I enter
in 15/7 it will give me everything from 9/7 to 15/7.

I entered "Between [Enter W/E Date] And ([Enter W/E Date]-6)" in the
field's criteria in the query, but, when running the query and entering
the w/e date, I then get a message saying that the expression is either
typed incorrectly or too complex to be evaluated.

Can anyone help me please?

Many thanks - David
 
Declare the parameter.

In query design view, choose Parameters on the Query menu.
In the dialog, enter:
[Enter W/E Date] Date/Time

That should help Access interpret what you enter. Try entering a full date
(including year.)

From your example, I take it you live in a d/m/y country, so you may also
get some help from:
International Date Formats in Access
at:
http://allenbrowne.com/ser-36.html
 
Back
Top