Dates Between And ??? (1 Viewer)

Mike A

Registered User.
Local time
Today, 21:05
Joined
Oct 17, 2000
Messages
14
Help!!!
I am trying to set up a Query to which I am adding a
'Between And' to the Criteria line on a Date column.

The first date references a 'From Date' field in a Date(s) Table...
The second date references a 'To Date' field in the Date(s) Table,
but nothing is coming up in the Query???

All dates are formatted as Date fields.
I have also tried adding #Date#, but this hasn't done anything either.

All help is highly appreciated! Thankyou!
 

chrismcbride

Registered User.
Local time
Today, 21:05
Joined
Sep 7, 2000
Messages
301
How are you getting the value to the query? Are you looking for user input at runtime?

If so in the Criteria line you type
BETWEEN [Enter Start Date] AND [Enter End Date]

If you are looking to return values from a Form, then you use the Forms Collection, but the Form must be open at the time.

BETWEEN Forms!frmSource!start_date_control
AND Forms!frmSourcee!end_date_control
Hope this helps
Chris
 

Nancy

Registered User.
Local time
Today, 21:05
Joined
Jul 28, 2000
Messages
21
Also, I believe that you'll want to go to the Parameters box (right click in the upper area of the query for a menu), and state the parameters along with a format of Date/Time.
 

Mike A

Registered User.
Local time
Today, 21:05
Joined
Oct 17, 2000
Messages
14
Between [Date Query Ranges]![From Date]
And [Date Query Ranges]![To Date]

Didn't work...
will try the parameters suggestion.

I am trying to set up a Query from which I can run a Report. There is a Date column in the Query now and I am trying to Report Between 2 dates set up in a Table, using the above references.

Tks for the comments!
 

Mike A

Registered User.
Local time
Today, 21:05
Joined
Oct 17, 2000
Messages
14
Yes!!!
Thankyou!!!
The Parameter setting solved the problem!
Thankyou! Thankyou!
 

Users who are viewing this thread

Top Bottom